Commit 615fa7cf authored by Ignacio Casal Quinteiro's avatar Ignacio Casal Quinteiro

Merge branch '379-fix-quartz-offscreen-window-crash' into 'gtk-3-24'

Resolve "gtkdnd-quartz crash when realizing a GtkOffscreenWindow"

See merge request !145
parents 00034c00 df0e5cc8
Pipeline #36511 passed with stage
in 6 minutes and 21 seconds
......@@ -36,6 +36,7 @@
#include "gtkimageprivate.h"
#include "gtkinvisible.h"
#include "gtkmain.h"
#include "gtkoffscreenwindow.h"
#include "deprecated/gtkstock.h"
#include "gtkwindow.h"
#include "gtkintl.h"
......@@ -354,7 +355,11 @@ get_toplevel_nswindow (GtkWidget *widget)
{
GtkWidget *toplevel = gtk_widget_get_toplevel (widget);
GdkWindow *window = gtk_widget_get_window (toplevel);
/* Offscreen windows don't support drag and drop */
if (GTK_IS_OFFSCREEN_WINDOW (toplevel))
return NULL;
if (gtk_widget_is_toplevel (toplevel) && window)
return [gdk_quartz_window_get_nsview (window) window];
else
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment