[gimp/gtk3-port: 230/237] app: use gdk_device_get_position() instead of gdk_display_get_pointer()
- From: Michael Natterer <mitch src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gimp/gtk3-port: 230/237] app: use gdk_device_get_position() instead of gdk_display_get_pointer()
- Date: Sat, 7 May 2011 20:19:17 +0000 (UTC)
commit 8c4bd5a2680d7d8fa8796901a3492dc708553558
Author: Michael Natterer <mitch gimp org>
Date: Mon Mar 28 20:51:17 2011 +0200
app: use gdk_device_get_position() instead of gdk_display_get_pointer()
app/gui/gui-vtable.c | 10 +++++++---
1 files changed, 7 insertions(+), 3 deletions(-)
---
diff --git a/app/gui/gui-vtable.c b/app/gui/gui-vtable.c
index 2207a6f..cb903b0 100644
--- a/app/gui/gui-vtable.c
+++ b/app/gui/gui-vtable.c
@@ -248,10 +248,14 @@ gui_get_display_name (Gimp *gimp,
}
else
{
- gint x, y;
+ GdkDeviceManager *device_manager;
+ GdkDevice *device;
+ gint x, y;
- gdk_display_get_pointer (gdk_display_get_default (),
- &screen, &x, &y, NULL);
+ device_manager = gdk_display_get_device_manager (gdk_display_get_default ());
+ device = gdk_device_manager_get_client_pointer (device_manager);
+
+ gdk_device_get_position (device, &screen, &x, &y);
monitor = gdk_screen_get_monitor_at_point (screen, x, y);
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]