71 lines
2.8 KiB
Diff
71 lines
2.8 KiB
Diff
From 64b9787f8c2996e915474103044062a534924f38 Mon Sep 17 00:00:00 2001
|
|
From: Nils Philippsen <nils@redhat.com>
|
|
Date: Wed, 14 Nov 2012 17:16:53 +0100
|
|
Subject: [PATCH] patch: file-dialog-toplevel
|
|
|
|
Squashed commit of the following:
|
|
|
|
commit b46df3e435d16819f1054f412b9adc2fc404c6ec
|
|
Author: Nils Philippsen <nils@redhat.com>
|
|
Date: Wed Nov 14 16:43:06 2012 +0100
|
|
|
|
app: remove check which hides conditions that should not happen
|
|
|
|
Remove a GTK_IS_WINDOW() check where this would hide parent widgets
|
|
being passed in that don't have a gtk toplevel. This should not happen
|
|
and if it does we want to know about it.
|
|
(cherry picked from commit f6f8079013401eecaa11e5f8bdd2688e51fd6602)
|
|
|
|
commit 7f6370fb0314308a32f3db82473a1a109ba1b1ca
|
|
Author: Nils Philippsen <nils@redhat.com>
|
|
Date: Wed Nov 14 16:42:05 2012 +0100
|
|
|
|
app: fix marking file dialogs as transient if opened from context menu
|
|
|
|
GimpDisplayShell isn't a GtkWindow (anymore), therefore use
|
|
gtk_widget_get_toplevel() to find the actual toplevel window.
|
|
(cherry picked from commit 1a4087bd5f1c79859fbfc417eff58f8e7783f335)
|
|
---
|
|
app/actions/file-commands.c | 11 ++++-------
|
|
1 file changed, 4 insertions(+), 7 deletions(-)
|
|
|
|
diff --git a/app/actions/file-commands.c b/app/actions/file-commands.c
|
|
index cbf82de..94a23a0 100644
|
|
--- a/app/actions/file-commands.c
|
|
+++ b/app/actions/file-commands.c
|
|
@@ -522,11 +522,8 @@ file_open_dialog_show (Gimp *gimp,
|
|
gimp_file_dialog_set_open_image (GIMP_FILE_DIALOG (dialog),
|
|
image, open_as_layers);
|
|
|
|
- parent = gtk_widget_get_toplevel (parent);
|
|
-
|
|
- if (GTK_IS_WINDOW (parent))
|
|
- gtk_window_set_transient_for (GTK_WINDOW (dialog),
|
|
- GTK_WINDOW (parent));
|
|
+ gtk_window_set_transient_for (GTK_WINDOW (dialog),
|
|
+ GTK_WINDOW (gtk_widget_get_toplevel (parent)));
|
|
|
|
gtk_window_present (GTK_WINDOW (dialog));
|
|
}
|
|
@@ -555,7 +552,7 @@ file_save_dialog_show (Gimp *gimp,
|
|
if (dialog)
|
|
{
|
|
gtk_window_set_transient_for (GTK_WINDOW (dialog),
|
|
- GTK_WINDOW (parent));
|
|
+ GTK_WINDOW (gtk_widget_get_toplevel (parent)));
|
|
|
|
g_object_set_data_full (G_OBJECT (image),
|
|
"gimp-file-save-dialog", dialog,
|
|
@@ -606,7 +603,7 @@ file_export_dialog_show (Gimp *gimp,
|
|
if (dialog)
|
|
{
|
|
gtk_window_set_transient_for (GTK_WINDOW (dialog),
|
|
- GTK_WINDOW (parent));
|
|
+ GTK_WINDOW (gtk_widget_get_toplevel (parent)));
|
|
|
|
g_object_set_data_full (G_OBJECT (image),
|
|
"gimp-file-export-dialog", dialog,
|
|
--
|
|
1.7.11.7
|
|
|