[gtk/wip/chergert/gdk-macos-fixes: 1/3] macos: fix compiler warnings
- From: Christian Hergert <chergert src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk/wip/chergert/gdk-macos-fixes: 1/3] macos: fix compiler warnings
- Date: Wed, 14 Oct 2020 18:34:50 +0000 (UTC)
commit d6abc125adf99b8edc7e6aacaaff0739fdf45ec1
Author: Christian Hergert <chergert redhat com>
Date: Mon Oct 12 20:11:35 2020 -0700
macos: fix compiler warnings
gtk/gtkfilechoosernativequartz.c | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)
---
diff --git a/gtk/gtkfilechoosernativequartz.c b/gtk/gtkfilechoosernativequartz.c
index 671e0acc3d..57ae3907f6 100644
--- a/gtk/gtkfilechoosernativequartz.c
+++ b/gtk/gtkfilechoosernativequartz.c
@@ -517,8 +517,12 @@ gtk_file_chooser_native_quartz_show (GtkFileChooserNative *self)
transient_for = gtk_native_dialog_get_transient_for (GTK_NATIVE_DIALOG (self));
if (transient_for)
{
+ GtkNative *native = GTK_NATIVE (transient_for);
+ GdkSurface *surface = gtk_native_get_surface (native);
+ NSWindow *window = _gdk_macos_surface_get_native (GDK_MACOS_SURFACE (surface));
+
gtk_widget_realize (GTK_WIDGET (transient_for));
- data->parent = _gdk_macos_surface_get_native (gtk_native_get_surface (GTK_NATIVE (transient_for)));
+ data->parent = window;
if (gtk_native_dialog_get_modal (GTK_NATIVE_DIALOG (self)))
data->modal = TRUE;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]