diff options
author | Caolán McNamara <caolanm@redhat.com> | 2021-06-21 13:10:40 +0100 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2021-06-21 16:07:16 +0200 |
commit | ca2515bab1b25fc7e6a703aca1e501656a963da4 (patch) | |
tree | 838f9d79a24ddcce5414a811b9a3328ccec4a6ae /cui/source/dialogs | |
parent | 203d96787969f707c78101be18d51b44ace98f93 (diff) |
use FileDialogHelper to set file picker parent
Change-Id: Ibca7a7d275773b816d125c38f87e902de7a5db4d
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/117583
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Diffstat (limited to 'cui/source/dialogs')
-rw-r--r-- | cui/source/dialogs/SignSignatureLineDialog.cxx | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/cui/source/dialogs/SignSignatureLineDialog.cxx b/cui/source/dialogs/SignSignatureLineDialog.cxx index 58a4fd317065..286f11501299 100644 --- a/cui/source/dialogs/SignSignatureLineDialog.cxx +++ b/cui/source/dialogs/SignSignatureLineDialog.cxx @@ -17,6 +17,7 @@ #include <comphelper/graphicmimetype.hxx> #include <comphelper/processfactory.hxx> +#include <sfx2/filedlghelper.hxx> #include <sfx2/objsh.hxx> #include <svx/xoutbmp.hxx> #include <utility> @@ -121,8 +122,9 @@ SignSignatureLineDialog::SignSignatureLineDialog(weld::Widget* pParent, Referenc IMPL_LINK_NOARG(SignSignatureLineDialog, loadImage, weld::Button&, void) { Reference<XComponentContext> xContext = comphelper::getProcessComponentContext(); - Reference<XFilePicker3> xFilePicker - = FilePicker::createWithMode(xContext, TemplateDescription::FILEOPEN_PREVIEW); + sfx2::FileDialogHelper aHelper(TemplateDescription::FILEOPEN_PREVIEW, FileDialogFlags::NONE, + m_xDialog.get()); + Reference<XFilePicker3> xFilePicker = aHelper.GetFilePicker(); if (!xFilePicker->execute()) return; |