[Libreoffice-commits] core.git: cui/source

Caolán McNamara (via logerrit) logerrit at kemper.freedesktop.org
Mon Jun 21 15:27:19 UTC 2021


 cui/source/options/optpath.cxx |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

New commits:
commit e3086b58eb5427d520b86c185f9d911bb6f7a3a0
Author:     Caolán McNamara <caolanm at redhat.com>
AuthorDate: Mon Jun 21 13:14:04 2021 +0100
Commit:     Caolán McNamara <caolanm at redhat.com>
CommitDate: Mon Jun 21 17:26:36 2021 +0200

    use FileDialogHelper to set file picker parent
    
    Change-Id: I970b34fd3da12a1051343bdc26afad411121e672
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/117584
    Tested-by: Jenkins
    Reviewed-by: Caolán McNamara <caolanm at redhat.com>

diff --git a/cui/source/options/optpath.cxx b/cui/source/options/optpath.cxx
index 0fe2ec033973..6e2cc6e48d61 100644
--- a/cui/source/options/optpath.cxx
+++ b/cui/source/options/optpath.cxx
@@ -567,8 +567,8 @@ IMPL_LINK_NOARG(SvxPathTabPage, PathHdl_Impl, weld::Button&, void)
     {
         try
         {
-            uno::Reference<uno::XComponentContext> xComponentContext(comphelper::getProcessComponentContext());
-            uno::Reference<ui::dialogs::XFilePicker3> xFilePicker = ui::dialogs::FilePicker::createWithMode(xComponentContext, ui::dialogs::TemplateDescription::FILEOPEN_SIMPLE);
+            sfx2::FileDialogHelper aHelper(ui::dialogs::TemplateDescription::FILEOPEN_SIMPLE, FileDialogFlags::NONE, GetFrameWeld());
+            uno::Reference<ui::dialogs::XFilePicker3> xFilePicker = aHelper.GetFilePicker();
             xFilePicker->appendFilter(OUString(), "*.xml");
             if (xFilePicker->execute() == ui::dialogs::ExecutableDialogResults::OK)
             {


More information about the Libreoffice-commits mailing list