summaryrefslogtreecommitdiff
path: root/sd
diff options
context:
space:
mode:
Diffstat (limited to 'sd')
-rw-r--r--sd/source/ui/animations/CustomAnimationDialog.cxx2
-rw-r--r--sd/source/ui/animations/SlideTransitionPane.cxx2
-rw-r--r--sd/source/ui/dlg/PhotoAlbumDialog.cxx2
-rw-r--r--sd/source/ui/dlg/filedlg.cxx10
-rw-r--r--sd/source/ui/dlg/tpaction.cxx5
-rw-r--r--sd/source/ui/func/fuinsert.cxx5
-rw-r--r--sd/source/ui/func/fuinsfil.cxx2
-rw-r--r--sd/source/ui/func/fupage.cxx4
-rw-r--r--sd/source/ui/inc/filedlg.hxx2
-rw-r--r--sd/source/ui/view/drviews2.cxx6
10 files changed, 21 insertions, 19 deletions
diff --git a/sd/source/ui/animations/CustomAnimationDialog.cxx b/sd/source/ui/animations/CustomAnimationDialog.cxx
index 8f697fc0b9e7..e8b332424b1c 100644
--- a/sd/source/ui/animations/CustomAnimationDialog.cxx
+++ b/sd/source/ui/animations/CustomAnimationDialog.cxx
@@ -1478,7 +1478,7 @@ sal_Int32 CustomAnimationEffectTabPage::getSoundObject( const OUString& rStr )
void CustomAnimationEffectTabPage::openSoundFileDialog()
{
- SdOpenSoundFileDialog aFileDialog;
+ SdOpenSoundFileDialog aFileDialog(this);
OUString aFile( SvtPathOptions().GetWorkPath() );
aFileDialog.SetPath( aFile );
diff --git a/sd/source/ui/animations/SlideTransitionPane.cxx b/sd/source/ui/animations/SlideTransitionPane.cxx
index 8763f095c2ba..2d9c135fbf6f 100644
--- a/sd/source/ui/animations/SlideTransitionPane.cxx
+++ b/sd/source/ui/animations/SlideTransitionPane.cxx
@@ -725,7 +725,7 @@ void SlideTransitionPane::openSoundFileDialog()
if( ! mpLB_SOUND->IsEnabled())
return;
- SdOpenSoundFileDialog aFileDialog;
+ SdOpenSoundFileDialog aFileDialog(this);
OUString aFile;
DBG_ASSERT( mpLB_SOUND->GetSelectEntryPos() == 2,
diff --git a/sd/source/ui/dlg/PhotoAlbumDialog.cxx b/sd/source/ui/dlg/PhotoAlbumDialog.cxx
index b70c7c7b7b92..89dae96b6ce9 100644
--- a/sd/source/ui/dlg/PhotoAlbumDialog.cxx
+++ b/sd/source/ui/dlg/PhotoAlbumDialog.cxx
@@ -501,7 +501,7 @@ IMPL_LINK_NOARG(SdPhotoAlbumDialog, FileHdl, Button*, void)
{
::sfx2::FileDialogHelper aDlg(
css::ui::dialogs::TemplateDescription::FILEOPEN_PREVIEW,
- FileDialogFlags::Graphic | FileDialogFlags::MultiSelection
+ FileDialogFlags::Graphic | FileDialogFlags::MultiSelection, this
);
// Read configuration
OUString sUrl(officecfg::Office::Impress::Pictures::Path::get());
diff --git a/sd/source/ui/dlg/filedlg.cxx b/sd/source/ui/dlg/filedlg.cxx
index 852dcad4fecc..f042354d3b7f 100644
--- a/sd/source/ui/dlg/filedlg.cxx
+++ b/sd/source/ui/dlg/filedlg.cxx
@@ -59,7 +59,7 @@ private:
DECL_LINK( IsMusicStoppedHdl, Timer *, void );
public:
- explicit SdFileDialog_Imp();
+ explicit SdFileDialog_Imp(const vcl::Window *pParent);
virtual ~SdFileDialog_Imp() override;
// overwritten from FileDialogHelper, to receive user feedback
@@ -174,8 +174,8 @@ IMPL_LINK_NOARG(SdFileDialog_Imp, IsMusicStoppedHdl, Timer *, void)
}
}
-SdFileDialog_Imp::SdFileDialog_Imp() :
- FileDialogHelper( css::ui::dialogs::TemplateDescription::FILEOPEN_LINK_PLAY ),
+SdFileDialog_Imp::SdFileDialog_Imp(const vcl::Window* pParent) :
+ FileDialogHelper(css::ui::dialogs::TemplateDescription::FILEOPEN_LINK_PLAY, FileDialogFlags::NONE, pParent),
mnPlaySoundEvent( nullptr ),
mbLabelPlaying(false)
{
@@ -212,8 +212,8 @@ SdFileDialog_Imp::~SdFileDialog_Imp()
// ----------- SdOpenSoundFileDialog -----------------------
// these are simple forwarders
-SdOpenSoundFileDialog::SdOpenSoundFileDialog() :
- mpImpl( new SdFileDialog_Imp() )
+SdOpenSoundFileDialog::SdOpenSoundFileDialog(const vcl::Window *pParent) :
+ mpImpl( new SdFileDialog_Imp(pParent) )
{
OUString aDescr;
aDescr = SdResId(STR_ALL_FILES);
diff --git a/sd/source/ui/dlg/tpaction.cxx b/sd/source/ui/dlg/tpaction.cxx
index 9f0d25a4641c..9f6b8f24bc3e 100644
--- a/sd/source/ui/dlg/tpaction.cxx
+++ b/sd/source/ui/dlg/tpaction.cxx
@@ -411,7 +411,7 @@ void SdTPAction::OpenFileDialog()
if (bSound)
{
- SdOpenSoundFileDialog aFileDialog;
+ SdOpenSoundFileDialog aFileDialog(this);
if( aFile.isEmpty() )
aFile = SvtPathOptions().GetWorkPath();
@@ -437,7 +437,8 @@ void SdTPAction::OpenFileDialog()
else
{
sfx2::FileDialogHelper aFileDialog(
- ui::dialogs::TemplateDescription::FILEOPEN_READONLY_VERSION);
+ ui::dialogs::TemplateDescription::FILEOPEN_READONLY_VERSION,
+ FileDialogFlags::NONE, this);
if (bDocument && aFile.isEmpty())
aFile = SvtPathOptions().GetWorkPath();
diff --git a/sd/source/ui/func/fuinsert.cxx b/sd/source/ui/func/fuinsert.cxx
index 67efed274d2b..99b653e283c5 100644
--- a/sd/source/ui/func/fuinsert.cxx
+++ b/sd/source/ui/func/fuinsert.cxx
@@ -140,7 +140,7 @@ void FuInsertGraphic::DoExecute( SfxRequest& rReq )
}
else
{
- SvxOpenGraphicDialog aDlg(SdResId(STR_INSERTGRAPHIC));
+ SvxOpenGraphicDialog aDlg(SdResId(STR_INSERTGRAPHIC), mpWindow);
if( aDlg.Execute() != ERRCODE_NONE )
return; // cancel dialog
@@ -775,7 +775,8 @@ rtl::Reference<FuPoor> FuInsert3DModel::Create( ViewShell* pViewSh, ::sd::Window
void FuInsert3DModel::DoExecute( SfxRequest& )
{
- sfx2::FileDialogHelper aDlg( ui::dialogs::TemplateDescription::FILEOPEN_SIMPLE );
+ sfx2::FileDialogHelper aDlg(ui::dialogs::TemplateDescription::FILEOPEN_SIMPLE,
+ FileDialogFlags::NONE, mpWindow);
aDlg.SetTitle( SdResId( STR_INSERT_3D_MODEL_TITLE ) );
diff --git a/sd/source/ui/func/fuinsfil.cxx b/sd/source/ui/func/fuinsfil.cxx
index d72701c527e9..210d8d95a4cd 100644
--- a/sd/source/ui/func/fuinsfil.cxx
+++ b/sd/source/ui/func/fuinsfil.cxx
@@ -138,7 +138,7 @@ void FuInsertFile::DoExecute( SfxRequest& rReq )
{
sfx2::FileDialogHelper aFileDialog(
ui::dialogs::TemplateDescription::FILEOPEN_SIMPLE,
- FileDialogFlags::Insert );
+ FileDialogFlags::Insert, mpWindow);
Reference< XFilePicker > xFilePicker( aFileDialog.GetFilePicker(), UNO_QUERY );
Reference< XFilterManager > xFilterManager( xFilePicker, UNO_QUERY );
OUString aOwnCont;
diff --git a/sd/source/ui/func/fupage.cxx b/sd/source/ui/func/fupage.cxx
index e02551a325e4..3b97ae868e91 100644
--- a/sd/source/ui/func/fupage.cxx
+++ b/sd/source/ui/func/fupage.cxx
@@ -301,12 +301,12 @@ const SfxItemSet* FuPage::ExecuteDialog( vcl::Window* pParent )
const XFillBitmapItem& rBitmap =
static_cast<const XFillBitmapItem&>(aMergedAttr.Get(XATTR_FILLBITMAP));
const GraphicObject& rGraphicObj = rBitmap.GetGraphicObject();
- GraphicHelper::ExportGraphic(rGraphicObj.GetGraphic(), "");
+ GraphicHelper::ExportGraphic(pParent, rGraphicObj.GetGraphic(), "");
}
}
else if (nId == SID_SELECT_BACKGROUND)
{
- SvxOpenGraphicDialog aDlg(SdResId(STR_SET_BACKGROUND_PICTURE));
+ SvxOpenGraphicDialog aDlg(SdResId(STR_SET_BACKGROUND_PICTURE), pParent);
if( aDlg.Execute() == ERRCODE_NONE )
{
diff --git a/sd/source/ui/inc/filedlg.hxx b/sd/source/ui/inc/filedlg.hxx
index 7712bb58eaf9..cd68b6cd7fd6 100644
--- a/sd/source/ui/inc/filedlg.hxx
+++ b/sd/source/ui/inc/filedlg.hxx
@@ -44,7 +44,7 @@ class SD_DLLPUBLIC SdOpenSoundFileDialog
SdOpenSoundFileDialog & operator= (const SdOpenSoundFileDialog &) = delete;
public:
- SdOpenSoundFileDialog();
+ SdOpenSoundFileDialog(const vcl::Window* pParent);
~SdOpenSoundFileDialog();
ErrCode Execute();
diff --git a/sd/source/ui/view/drviews2.cxx b/sd/source/ui/view/drviews2.cxx
index cbfb9c01a6c0..cbd8088f8e8d 100644
--- a/sd/source/ui/view/drviews2.cxx
+++ b/sd/source/ui/view/drviews2.cxx
@@ -927,11 +927,11 @@ void DrawViewShell::FuTemporary(SfxRequest& rReq)
const SdrGrafObj* pObj = dynamic_cast<const SdrGrafObj*>(rMarkList.GetMark(0)->GetMarkedSdrObj());
if (pObj && pObj->GetGraphicType() == GraphicType::Bitmap)
{
+ vcl::Window* pWin = GetActiveWindow();
GraphicAttr aGraphicAttr = pObj->GetGraphicAttr();
short nState = RET_CANCEL;
if (aGraphicAttr != GraphicAttr()) // the image has been modified
{
- vcl::Window* pWin = GetActiveWindow();
if (pWin)
{
nState = GraphicHelper::HasToSaveTransformedImage(pWin);
@@ -944,12 +944,12 @@ void DrawViewShell::FuTemporary(SfxRequest& rReq)
if (nState == RET_YES)
{
- GraphicHelper::ExportGraphic( pObj->GetTransformedGraphic(), "" );
+ GraphicHelper::ExportGraphic(pWin, pObj->GetTransformedGraphic(), "");
}
else if (nState == RET_NO)
{
GraphicObject aGraphicObject(pObj->GetGraphicObject());
- GraphicHelper::ExportGraphic( aGraphicObject.GetGraphic(), "" );
+ GraphicHelper::ExportGraphic(pWin, aGraphicObject.GetGraphic(), "");
}
}
}