summaryrefslogtreecommitdiff
path: root/vcl
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2016-06-16 21:07:01 +0100
committerCaolán McNamara <caolanm@redhat.com>2016-06-16 21:08:33 +0100
commit83b7c1ae8068787212f757b9c8b9c317537a2dd2 (patch)
treed7beb8b7052e49fc90252edbd916b5f0936f1081 /vcl
parent1c0d1199fe02666de0d162f071ce7e6e812a23df (diff)
Resolves: tdf#100327 gtk3 fpicker yes/no dialog modal trouble
not sure why we ever hid the file dialog when putting up the yes/no dialog. So lets just do the more apparently sensible thing on the gtk3 path and leave gtk2 alone. Probably fallout from using window groups Change-Id: I4d0e8fae9568b050b674cf6ef4d8c88e65dd2ca1 (cherry picked from commit e50caebc02ee2045a38a39b4a4c644da0d678541)
Diffstat (limited to 'vcl')
-rw-r--r--vcl/unx/gtk/fpicker/SalGtkFilePicker.cxx4
-rw-r--r--vcl/unx/gtk/fpicker/SalGtkPicker.cxx2
2 files changed, 6 insertions, 0 deletions
diff --git a/vcl/unx/gtk/fpicker/SalGtkFilePicker.cxx b/vcl/unx/gtk/fpicker/SalGtkFilePicker.cxx
index 44fccb0bfd60..4a9453b7884c 100644
--- a/vcl/unx/gtk/fpicker/SalGtkFilePicker.cxx
+++ b/vcl/unx/gtk/fpicker/SalGtkFilePicker.cxx
@@ -1009,8 +1009,12 @@ sal_Int16 SAL_CALL SalGtkFilePicker::execute() throw( uno::RuntimeException, std
gtk_window_set_title( GTK_WINDOW( dlg ),
OUStringToOString(getResString(FILE_PICKER_TITLE_SAVE ),
RTL_TEXTENCODING_UTF8 ).getStr() );
+#if GTK_CHECK_VERSION(3,0,0)
+ gtk_window_set_transient_for(GTK_WINDOW(dlg), GTK_WINDOW(m_pDialog));
+#else
if (pParent)
gtk_window_set_transient_for(GTK_WINDOW(dlg), pParent);
+#endif
RunDialog* pAnotherDialog = new RunDialog(dlg, xToolkit);
uno::Reference < awt::XTopWindowListener > xAnotherLifeCycle(pAnotherDialog);
btn = pAnotherDialog->run();
diff --git a/vcl/unx/gtk/fpicker/SalGtkPicker.cxx b/vcl/unx/gtk/fpicker/SalGtkPicker.cxx
index 96df4b7617a1..968051d4b36a 100644
--- a/vcl/unx/gtk/fpicker/SalGtkPicker.cxx
+++ b/vcl/unx/gtk/fpicker/SalGtkPicker.cxx
@@ -182,8 +182,10 @@ gint RunDialog::run()
if (mxToolkit.is())
mxToolkit->removeTopWindowListener(this);
+#if !GTK_CHECK_VERSION(3,0,0)
if (nStatus != 1) //PLAY
gtk_widget_hide( mpDialog );
+#endif
return nStatus;
}