[Libreoffice-commits] core.git: vcl/unx

Libreoffice Gerrit user logerrit at kemper.freedesktop.org
Thu Nov 8 12:47:16 UTC 2018


 vcl/unx/gtk/fpicker/SalGtkFilePicker.cxx |    9 +++++++++
 1 file changed, 9 insertions(+)

New commits:
commit 35b6f75bc14fe65c4700e199d82c958f715420ac
Author:     Caolán McNamara <caolanm at redhat.com>
AuthorDate: Thu Nov 8 09:58:58 2018 +0000
Commit:     Caolán McNamara <caolanm at redhat.com>
CommitDate: Thu Nov 8 13:45:39 2018 +0100

    Resolves: tdf#119790 for gtk3 save and restore typed name on changing filter
    
    Change-Id: I17c3d154144b13ce401b0e4afe84c91a2fe98d8e
    Reviewed-on: https://gerrit.libreoffice.org/63075
    Tested-by: Jenkins
    Reviewed-by: Caolán McNamara <caolanm at redhat.com>
    Tested-by: Caolán McNamara <caolanm at redhat.com>

diff --git a/vcl/unx/gtk/fpicker/SalGtkFilePicker.cxx b/vcl/unx/gtk/fpicker/SalGtkFilePicker.cxx
index d5fd865747ba..b4603bb32a80 100644
--- a/vcl/unx/gtk/fpicker/SalGtkFilePicker.cxx
+++ b/vcl/unx/gtk/fpicker/SalGtkFilePicker.cxx
@@ -806,7 +806,16 @@ uno::Sequence<OUString> SAL_CALL SalGtkFilePicker::getSelectedFiles()
                             }
                         }
                         if( bChangeFilter && bExtensionTypedIn )
+                        {
+#if GTK_CHECK_VERSION(3,0,0)
+                            gchar* pCurrentName = gtk_file_chooser_get_current_name(GTK_FILE_CHOOSER(m_pDialog));
+                            setCurrentFilter( aNewFilter );
+                            gtk_file_chooser_set_current_name(GTK_FILE_CHOOSER(m_pDialog), pCurrentName);
+                            g_free(pCurrentName);
+#else
                             setCurrentFilter( aNewFilter );
+#endif
+                        }
                     }
                 }
 


More information about the Libreoffice-commits mailing list