[gtk+/wip/baedert/drawing] range: Fix mark positions
- From: Timm Bäder <baedert src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk+/wip/baedert/drawing] range: Fix mark positions
- Date: Fri, 30 Jun 2017 11:37:47 +0000 (UTC)
commit b6cec097c0ed03cac360a7047bce86ec1be5de53
Author: Timm Bäder <mail baedert org>
Date: Fri Jun 30 13:10:32 2017 +0200
range: Fix mark positions
The values returned by gtk_range_compute_slider_position are relative
to the trough_widget (the slider's parent), not the slider widget
itself.
gtk/gtkrange.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
---
diff --git a/gtk/gtkrange.c b/gtk/gtkrange.c
index 2c4d208..70220c9 100644
--- a/gtk/gtkrange.c
+++ b/gtk/gtkrange.c
@@ -2910,7 +2910,7 @@ gtk_range_calc_marks (GtkRange *range)
for (i = 0; i < priv->n_marks; i++)
{
gtk_range_compute_slider_position (range, priv->marks[i], &slider);
- gtk_widget_translate_coordinates (priv->slider_widget, GTK_WIDGET (range),
+ gtk_widget_translate_coordinates (priv->trough_widget, GTK_WIDGET (range),
slider.x, slider.y, &slider.x, &slider.y);
if (priv->orientation == GTK_ORIENTATION_HORIZONTAL)
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]