From 9f016bd69422bdfb4cf7c4f5e57356eb98db2d8c Mon Sep 17 00:00:00 2001 From: Michael Meeks Date: Mon, 11 May 2015 14:02:42 +0100 Subject: Switch VclBuilder constructors to use VclPtr. Change-Id: Id35a86eb52bbde6ca09a5e61a0b1a79b23be8faf --- sc/source/ui/cctrl/editfield.cxx | 2 +- sc/source/ui/condformat/condformatdlg.cxx | 2 +- sc/source/ui/dbgui/pvfundlg.cxx | 2 +- sc/source/ui/dbgui/validate.cxx | 2 +- sc/source/ui/miscdlgs/tabbgcolordlg.cxx | 2 +- sc/source/ui/pagedlg/tphfedit.cxx | 2 +- 6 files changed, 6 insertions(+), 6 deletions(-) (limited to 'sc') diff --git a/sc/source/ui/cctrl/editfield.cxx b/sc/source/ui/cctrl/editfield.cxx index 78650e663c85..864bfc0fddbf 100644 --- a/sc/source/ui/cctrl/editfield.cxx +++ b/sc/source/ui/cctrl/editfield.cxx @@ -49,7 +49,7 @@ ScDoubleField::ScDoubleField( vcl::Window* pParent, WinBits nStyle ) : VCL_BUILDER_DECL_FACTORY(ScDoubleField) { VclBuilder::ensureDefaultWidthChars(rMap); - return new ScDoubleField(pParent, WB_LEFT|WB_VCENTER|WB_BORDER|WB_3DLOOK); + return VclPtr::Create(pParent, WB_LEFT|WB_VCENTER|WB_BORDER|WB_3DLOOK); } bool ScDoubleField::GetValue( double& rfValue ) const diff --git a/sc/source/ui/condformat/condformatdlg.cxx b/sc/source/ui/condformat/condformatdlg.cxx index 0e2cbf5738d5..2ec29d676811 100644 --- a/sc/source/ui/condformat/condformatdlg.cxx +++ b/sc/source/ui/condformat/condformatdlg.cxx @@ -151,7 +151,7 @@ VCL_BUILDER_DECL_FACTORY(ScCondFormatList) if (!sBorder.isEmpty()) nWinBits |= WB_BORDER; - return new ScCondFormatList(pParent, nWinBits); + return VclPtr::Create(pParent, nWinBits); } Size ScCondFormatList::GetOptimalSize() const diff --git a/sc/source/ui/dbgui/pvfundlg.cxx b/sc/source/ui/dbgui/pvfundlg.cxx index 8ef5c95ed950..617efcc33ed4 100644 --- a/sc/source/ui/dbgui/pvfundlg.cxx +++ b/sc/source/ui/dbgui/pvfundlg.cxx @@ -163,7 +163,7 @@ VCL_BUILDER_DECL_FACTORY(ScDPFunctionListBox) OString sBorder = VclBuilder::extractCustomProperty(rMap); if (!sBorder.isEmpty()) nWinStyle |= WB_BORDER; - return new ScDPFunctionListBox(pParent, nWinStyle); + return VclPtr::Create(pParent, nWinStyle); } void ScDPFunctionListBox::SetSelection( sal_uInt16 nFuncMask ) diff --git a/sc/source/ui/dbgui/validate.cxx b/sc/source/ui/dbgui/validate.cxx index 187fefdddfe3..67d435cfa301 100644 --- a/sc/source/ui/dbgui/validate.cxx +++ b/sc/source/ui/dbgui/validate.cxx @@ -940,7 +940,7 @@ bool ScValidationDlg::RemoveRefDlg( bool bRestoreModal /* = true */ ) VCL_BUILDER_DECL_FACTORY(ScRefButtonEx) { (void)rMap; - return new ScTPValidationValue::ScRefButtonEx(pParent, 0); + return VclPtr::Create(pParent, 0); } void ScTPValidationValue::ScRefButtonEx::Click() diff --git a/sc/source/ui/miscdlgs/tabbgcolordlg.cxx b/sc/source/ui/miscdlgs/tabbgcolordlg.cxx index 55aacefed994..477f5199bbb4 100644 --- a/sc/source/ui/miscdlgs/tabbgcolordlg.cxx +++ b/sc/source/ui/miscdlgs/tabbgcolordlg.cxx @@ -166,7 +166,7 @@ VCL_BUILDER_DECL_FACTORY(ScTabBgColorValueSet) if (!sBorder.isEmpty()) nWinBits |= WB_BORDER; - return new ScTabBgColorDlg::ScTabBgColorValueSet(pParent, nWinBits); + return VclPtr::Create(pParent, nWinBits); } void ScTabBgColorDlg::ScTabBgColorValueSet::KeyInput( const KeyEvent& rKEvt ) diff --git a/sc/source/ui/pagedlg/tphfedit.cxx b/sc/source/ui/pagedlg/tphfedit.cxx index 38ed89456f5d..7b1af0a6610d 100644 --- a/sc/source/ui/pagedlg/tphfedit.cxx +++ b/sc/source/ui/pagedlg/tphfedit.cxx @@ -139,7 +139,7 @@ void ScEditWindow::dispose() VCL_BUILDER_DECL_FACTORY(ScEditWindow) { (void)rMap; - return new ScEditWindow (pParent, WB_BORDER|WB_TABSTOP, Left); + return VclPtr::Create(pParent, WB_BORDER|WB_TABSTOP, Left); } void ScEditWindow::SetNumType(SvxNumType eNumType) -- cgit