diff options
author | Xan Lopez <xan@gnome.org> | 2009-02-25 17:38:53 +0000 |
---|---|---|
committer | Xan Lopez <xan@src.gnome.org> | 2009-02-25 17:38:53 +0000 |
commit | 7871e095605332ce1cfb15e19a06f36b05604d0b (patch) | |
tree | eec2735a4c72e5506a37c042316914d2ec814479 /gtk/gtkrange.c | |
parent | 4708c01a2024957be57e4088d8d6afaac2d668c1 (diff) | |
download | gtk+-7871e095605332ce1cfb15e19a06f36b05604d0b.tar.gz |
Bug 495320 - GtkRange does not use gdk_event_request_motions
2009-02-25 Xan Lopez <xan@gnome.org>
Bug 495320 - GtkRange does not use gdk_event_request_motions
* gtk/gtkrange.c:
(gtk_range_motion_notify): Use gdk_event_request_motions to
request more motion events, as suggested in the docs for widgets
using motion hints.
svn path=/trunk/; revision=22407
Diffstat (limited to 'gtk/gtkrange.c')
-rw-r--r-- | gtk/gtkrange.c | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/gtk/gtkrange.c b/gtk/gtkrange.c index 6db35b5f11..0c1b313b5a 100644 --- a/gtk/gtkrange.c +++ b/gtk/gtkrange.c @@ -2280,20 +2280,19 @@ gtk_range_motion_notify (GtkWidget *widget, GdkEventMotion *event) { GtkRange *range; - gint x, y; range = GTK_RANGE (widget); - gdk_window_get_pointer (range->event_window, &x, &y, NULL); + gdk_event_request_motions (event); - range->layout->mouse_x = x; - range->layout->mouse_y = y; + range->layout->mouse_x = event->x; + range->layout->mouse_y = event->y; if (gtk_range_update_mouse_location (range)) gtk_widget_queue_draw (widget); if (range->layout->grab_location == MOUSE_SLIDER) - update_slider_position (range, x, y); + update_slider_position (range, event->x, event->y); /* We handled the event if the mouse was in the range_rect */ return range->layout->mouse_location != MOUSE_OUTSIDE; |