diff options
Diffstat (limited to 'src/ui/frames.c')
-rw-r--r-- | src/ui/frames.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/src/ui/frames.c b/src/ui/frames.c index 1444c1ed9..83003ee49 100644 --- a/src/ui/frames.c +++ b/src/ui/frames.c @@ -1942,7 +1942,7 @@ meta_frames_motion_notify_event (GtkWidget *widget, Display *display; frames = META_FRAMES (widget); - display = GDK_DISPLAY_XDISPLAY (gdk_display_get_default ()); + display = GDK_DISPLAY_XDISPLAY (gdk_window_get_display (event->window)); frame = meta_frames_lookup_window (frames, GDK_WINDOW_XID (event->window)); if (frame == NULL) @@ -1971,7 +1971,8 @@ meta_frames_motion_notify_event (GtkWidget *widget, MetaFrameControl control; int x, y; - gdk_window_get_pointer (frame->window, &x, &y, NULL); + gdk_window_get_device_position (frame->window, event->device, + &x, &y, NULL); /* Control is set to none unless it matches * the current grab @@ -2012,7 +2013,8 @@ meta_frames_motion_notify_event (GtkWidget *widget, MetaFrameControl control; int x, y; - gdk_window_get_pointer (frame->window, &x, &y, NULL); + gdk_window_get_device_position (frame->window, event->device, + &x, &y, NULL); control = get_control (frames, frame, x, y); |