Kaydet (Commit) a1cfd9ff authored tarafından Xisco Fauli's avatar Xisco Fauli Kaydeden (comit) Noel Grandin

tdf#89329: use unique_ptr for pImpl in new

Fix "error: declaration of ‘pImpl’ shadows a
member of 'this' [-Werror=shadow]" too

Change-Id: Ib0fc66375ed7d9ae700d5a81a2adb5975fcae592
Reviewed-on: https://gerrit.libreoffice.org/25319Tested-by: 's avatarJenkins <ci@libreoffice.org>
Reviewed-by: 's avatarNoel Grandin <noelgrandin@gmail.com>
üst ea0f6333
......@@ -59,7 +59,7 @@ class SFX2_DLLPUBLIC SfxNewFileDialog : public SfxModalDialog
friend class SfxNewFileDialog_Impl;
private:
SfxNewFileDialog_Impl* pImpl;
std::unique_ptr< SfxNewFileDialog_Impl > pImpl;
public:
......
......@@ -423,9 +423,9 @@ SfxNewFileDialog_Impl::~SfxNewFileDialog_Impl()
SfxNewFileDialog::SfxNewFileDialog(vcl::Window *pParent, sal_uInt16 nFlags)
: SfxModalDialog(pParent, "LoadTemplateDialog",
"sfx/ui/loadtemplatedialog.ui")
"sfx/ui/loadtemplatedialog.ui"),
pImpl( new SfxNewFileDialog_Impl(this, nFlags) )
{
pImpl = new SfxNewFileDialog_Impl(this, nFlags);
}
SfxNewFileDialog::~SfxNewFileDialog()
......@@ -435,7 +435,7 @@ SfxNewFileDialog::~SfxNewFileDialog()
void SfxNewFileDialog::dispose()
{
delete pImpl;
pImpl.reset();
SfxModalDialog::dispose();
}
......
......@@ -1763,8 +1763,8 @@ void SwView::NotifyDBChanged()
SfxObjectShellLock SwView::CreateTmpSelectionDoc()
{
SwXTextView *const pImpl = GetViewImpl()->GetUNOObject_Impl();
return pImpl->BuildTmpSelectionDoc();
SwXTextView *const pTempImpl = GetViewImpl()->GetUNOObject_Impl();
return pTempImpl->BuildTmpSelectionDoc();
}
void SwView::AddTransferable(SwTransferable& rTransferable)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment