[gtk/gtk-3-24-fixeventloop] move [NSApplication sharedApplication] after _gdk_quartz_events_init() to avoid initialization issue



commit 46c2451c5a3cd42aa5a94935bfc850a484288ff3
Author: Oleksii Samorukov <samm os2 kiev ua>
Date:   Sun Jan 5 21:02:37 2020 +0100

    move [NSApplication sharedApplication] after _gdk_quartz_events_init() to avoid initialization issues

 gdk/quartz/gdkdisplay-quartz.c | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)
---
diff --git a/gdk/quartz/gdkdisplay-quartz.c b/gdk/quartz/gdkdisplay-quartz.c
index 0cce0d0250..29dc7093a3 100644
--- a/gdk/quartz/gdkdisplay-quartz.c
+++ b/gdk/quartz/gdkdisplay-quartz.c
@@ -88,9 +88,6 @@ _gdk_quartz_display_open (const gchar *display_name)
   if (_gdk_display != NULL)
     return NULL;
 
-  /* Initialize application */
-  [NSApplication sharedApplication];
-
   _gdk_display = g_object_new (gdk_quartz_display_get_type (), NULL);
   _gdk_display->device_manager = _gdk_device_manager_new (_gdk_display);
 
@@ -101,6 +98,8 @@ _gdk_quartz_display_open (const gchar *display_name)
 
   _gdk_quartz_events_init ();
 
+  /* Initialize application */
+  [NSApplication sharedApplication];
 #if 0
   /* FIXME: Remove the #if 0 when we have these functions */
   _gdk_quartz_dnd_init ();


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