[gtk+] quartz: Stop using gdk_display_get_default_screen



commit 44a173824eb27505ccff956c927179e9c2d4513a
Author: Matthias Clasen <mclasen redhat com>
Date:   Wed Nov 1 17:30:00 2017 -0400

    quartz: Stop using gdk_display_get_default_screen
    
    The GdkScreen api is going away. The quartz screen is
    a singleton anyway.

 gdk/quartz/gdkdevice-core-quartz.c |    4 ++--
 gdk/quartz/gdkmonitor-quartz.c     |    2 +-
 2 files changed, 3 insertions(+), 3 deletions(-)
---
diff --git a/gdk/quartz/gdkdevice-core-quartz.c b/gdk/quartz/gdkdevice-core-quartz.c
index a6f9582..8e5683a 100644
--- a/gdk/quartz/gdkdevice-core-quartz.c
+++ b/gdk/quartz/gdkdevice-core-quartz.c
@@ -330,8 +330,8 @@ gdk_quartz_device_core_window_at_position (GdkDevice       *device,
   NSPoint point;
   gint x_tmp, y_tmp;
 
-  display = gdk_device_get_display (device);
-  screen = gdk_display_get_default_screen (display);
+  display = _gdk_display;
+  screen = _gdk_screen;
 
   /* Get mouse coordinates, find window under the mouse pointer */
   point = [NSEvent mouseLocation];
diff --git a/gdk/quartz/gdkmonitor-quartz.c b/gdk/quartz/gdkmonitor-quartz.c
index ec36b23..8130f2f 100644
--- a/gdk/quartz/gdkmonitor-quartz.c
+++ b/gdk/quartz/gdkmonitor-quartz.c
@@ -30,7 +30,7 @@ static void
 gdk_quartz_monitor_get_workarea (GdkMonitor   *monitor,
                                  GdkRectangle *dest)
 {
-  GdkQuartzScreen *quartz_screen = GDK_QUARTZ_SCREEN(gdk_display_get_default_screen (monitor->display));
+  GdkQuartzScreen *quartz_screen = GDK_QUARTZ_SCREEN(_gdk_screen);
   GdkQuartzMonitor *quartz_monitor = GDK_QUARTZ_MONITOR(monitor);
 
   GDK_QUARTZ_ALLOC_POOL;


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]