From ceb6f473837261f2a6e43e028ce9da3daccc2f6c Mon Sep 17 00:00:00 2001 From: Michael Meeks Date: Mon, 11 May 2015 13:42:10 +0100 Subject: tdf#91052 - more macros for 'make' constructors. Change-Id: Iece86485c52041b66cde91d7fbc772db16d90a93 --- svx/source/dialog/dlgctl3d.cxx | 12 ++----- svx/source/dialog/dlgctrl.cxx | 42 +++++++---------------- svx/source/dialog/fntctrl.cxx | 4 +-- svx/source/dialog/fontlb.cxx | 4 +-- svx/source/dialog/frmdirlbox.cxx | 8 ++--- svx/source/dialog/frmsel.cxx | 5 +-- svx/source/dialog/graphctl.cxx | 3 +- svx/source/dialog/imapdlg.cxx | 6 ++-- svx/source/dialog/langbox.cxx | 8 ++--- svx/source/dialog/measctrl.cxx | 4 +-- svx/source/dialog/pagectrl.cxx | 9 ++--- svx/source/dialog/paraprev.cxx | 7 ++-- svx/source/dialog/rubydialog.cxx | 11 ++---- svx/source/dialog/svxbmpnumvalueset.cxx | 11 ++---- svx/source/dialog/swframeexample.cxx | 7 ++-- svx/source/dialog/txencbox.cxx | 4 +-- svx/source/form/datanavi.cxx | 6 ++-- svx/source/gallery2/galctrl.cxx | 4 +-- svx/source/sidebar/possize/SidebarDialControl.cxx | 7 ++-- svx/source/tbxctrls/SvxColorValueSet.cxx | 4 +-- svx/source/tbxctrls/itemwin.cxx | 15 ++------ sw/source/ui/chrdlg/drpcps.cxx | 6 ++-- sw/source/ui/config/optload.cxx | 6 ++-- sw/source/ui/config/optpage.cxx | 6 ++-- sw/source/ui/dbui/createaddresslistdialog.cxx | 4 ++- sw/source/ui/dbui/mmaddressblockpage.cxx | 11 +++--- sw/source/ui/envelp/envlop1.cxx | 7 ++-- sw/source/ui/envelp/labfmt.cxx | 6 ++-- sw/source/ui/fldui/FldRefTreeListBox.cxx | 4 +-- sw/source/ui/fldui/fldvar.cxx | 3 +- sw/source/ui/frmdlg/column.cxx | 6 ++-- sw/source/ui/frmdlg/frmpage.cxx | 6 ++-- sw/source/ui/index/cnttab.cxx | 8 ++--- sw/source/ui/misc/bookmark.cxx | 6 ++-- sw/source/ui/misc/glosbib.cxx | 13 +++---- sw/source/ui/misc/glossary.cxx | 6 ++-- sw/source/ui/misc/outline.cxx | 6 ++-- sw/source/ui/table/tautofmt.cxx | 3 +- sw/source/uibase/cctrl/actctrl.cxx | 4 +-- sw/source/uibase/dbui/dbtree.cxx | 4 +-- sw/source/uibase/dbui/mailmergehelper.cxx | 3 +- sw/source/uibase/frmdlg/colex.cxx | 16 +++------ sw/source/uibase/misc/numberingtypelistbox.cxx | 4 ++- sw/source/uibase/utlui/condedit.cxx | 4 +-- sw/source/uibase/utlui/numfmtlb.cxx | 3 +- 45 files changed, 117 insertions(+), 209 deletions(-) diff --git a/svx/source/dialog/dlgctl3d.cxx b/svx/source/dialog/dlgctl3d.cxx index 2972abdf60ce..748c92a189ef 100644 --- a/svx/source/dialog/dlgctl3d.cxx +++ b/svx/source/dialog/dlgctl3d.cxx @@ -28,7 +28,7 @@ #include #include #include -#include +#include #include #include #include @@ -62,10 +62,7 @@ Size Svx3DPreviewControl::GetOptimalSize() const return LogicToPixel(Size(80, 100), MAP_APPFONT); } -extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeSvx3DPreviewControl(vcl::Window *pParent, VclBuilder::stringmap &) -{ - return new Svx3DPreviewControl(pParent); -} +VCL_BUILDER_FACTORY(Svx3DPreviewControl) Svx3DPreviewControl::~Svx3DPreviewControl() { @@ -962,10 +959,7 @@ Size SvxLightCtl3D::GetOptimalSize() const return LogicToPixel(Size(80, 100), MAP_APPFONT); } -extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeSvxLightCtl3D(vcl::Window *pParent, VclBuilder::stringmap &) -{ - return new SvxLightCtl3D(pParent); -} +VCL_BUILDER_FACTORY(SvxLightCtl3D) void SvxLightCtl3D::Init() { diff --git a/svx/source/dialog/dlgctrl.cxx b/svx/source/dialog/dlgctrl.cxx index 7f9706176a4d..ad7c410a690d 100644 --- a/svx/source/dialog/dlgctrl.cxx +++ b/svx/source/dialog/dlgctrl.cxx @@ -17,7 +17,7 @@ * the License at http://www.apache.org/licenses/LICENSE-2.0 . */ -#include +#include #include #include #include @@ -97,12 +97,7 @@ Size SvxRectCtl::GetOptimalSize() const return LogicToPixel(Size(78, 39), MAP_APPFONT); } -extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeSvxRectCtl(vcl::Window *pParent, VclBuilder::stringmap &) -{ - return new SvxRectCtl(pParent); -} - - +VCL_BUILDER_FACTORY(SvxRectCtl) SvxRectCtl::~SvxRectCtl() { @@ -839,11 +834,7 @@ Size SvxPixelCtl::GetOptimalSize() const return LogicToPixel(Size(72, 72), MAP_APPFONT); } -extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeSvxPixelCtl(vcl::Window *pParent, VclBuilder::stringmap&) -{ - return new SvxPixelCtl(pParent, 8); -} -// Destructor dealocating the dynamic array +VCL_BUILDER_FACTORY_ARGS(SvxPixelCtl, 8) SvxPixelCtl::~SvxPixelCtl( ) { @@ -1141,7 +1132,7 @@ BitmapEx SvxBitmapCtl::GetBitmapEx() return BitmapEx(aRetval); } -extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeColorLB(vcl::Window *pParent, VclBuilder::stringmap &rMap) +VCL_BUILDER_DECL_FACTORY(ColorLB) { bool bDropdown = VclBuilder::extractDropdown(rMap); WinBits nWinBits = WB_LEFT|WB_VCENTER|WB_3DLOOK|WB_SIMPLEMODE|WB_TABSTOP; @@ -1196,7 +1187,7 @@ HatchingLB::HatchingLB( vcl::Window* pParent, WinBits nWinStyle) SetEdgeBlending(true); } -extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeHatchingLB(vcl::Window *pParent, VclBuilder::stringmap& rMap) +VCL_BUILDER_DECL_FACTORY(HatchingLB) { WinBits nWinStyle = WB_LEFT|WB_VCENTER|WB_3DLOOK|WB_SIMPLEMODE; OString sBorder = VclBuilder::extractCustomProperty(rMap); @@ -1289,7 +1280,7 @@ GradientLB::GradientLB( vcl::Window* pParent, WinBits aWB) SetEdgeBlending(true); } -extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeGradientLB(vcl::Window *pParent, VclBuilder::stringmap &rMap) +VCL_BUILDER_DECL_FACTORY(GradientLB) { WinBits nWinStyle = WB_LEFT|WB_VCENTER|WB_3DLOOK|WB_SIMPLEMODE; OString sBorder = VclBuilder::extractCustomProperty(rMap); @@ -1405,7 +1396,7 @@ BitmapLB::BitmapLB( vcl::Window* pParent, WinBits aWB) SetEdgeBlending(true); } -extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeBitmapLB(vcl::Window *pParent, VclBuilder::stringmap &rMap) +VCL_BUILDER_DECL_FACTORY(BitmapLB) { WinBits nWinStyle = WB_LEFT|WB_VCENTER|WB_3DLOOK|WB_SIMPLEMODE; OString sBorder = VclBuilder::extractCustomProperty(rMap); @@ -1575,7 +1566,7 @@ LineLB::LineLB(vcl::Window* pParent, WinBits aWB) // No EdgeBlending for LineStyle/Dash SetEdgeBlending(true); } -extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeLineLB(vcl::Window *pParent, VclBuilder::stringmap &rMap) +VCL_BUILDER_DECL_FACTORY(LineLB) { bool bDropdown = VclBuilder::extractDropdown(rMap); WinBits nWinBits = WB_LEFT|WB_VCENTER|WB_3DLOOK|WB_SIMPLEMODE|WB_TABSTOP; @@ -1673,7 +1664,7 @@ LineEndLB::LineEndLB( vcl::Window* pParent, WinBits aWB ) // No EdgeBlending for LineEnds SetEdgeBlending(true); } -extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeLineEndLB(vcl::Window *pParent, VclBuilder::stringmap &rMap) +VCL_BUILDER_DECL_FACTORY(LineEndLB) { bool bDropdown = VclBuilder::extractDropdown(rMap); WinBits nWinBits = WB_LEFT|WB_VCENTER|WB_3DLOOK|WB_SIMPLEMODE|WB_TABSTOP; @@ -1969,10 +1960,7 @@ SvxXLinePreview::SvxXLinePreview(vcl::Window* pParent) mpLineObjC->SetModel(&getModel()); } -extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeSvxXLinePreview(vcl::Window *pParent, VclBuilder::stringmap &) -{ - return new SvxXLinePreview(pParent); -} +VCL_BUILDER_FACTORY(SvxXLinePreview) Size SvxXLinePreview::GetOptimalSize() const { @@ -2086,10 +2074,7 @@ void SvxXRectPreview::Resize() SvxPreviewBase::Resize(); } -extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeSvxXRectPreview(vcl::Window *pParent, VclBuilder::stringmap &) -{ - return new SvxXRectPreview(pParent); -} +VCL_BUILDER_FACTORY(SvxXRectPreview) SvxXRectPreview::~SvxXRectPreview() { @@ -2147,10 +2132,7 @@ SvxXShadowPreview::SvxXShadowPreview( vcl::Window* pParent ) mpRectangleShadow->SetModel(&getModel()); } -extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeSvxXShadowPreview (vcl::Window *pParent, VclBuilder::stringmap &) -{ - return new SvxXShadowPreview(pParent); -} +VCL_BUILDER_FACTORY(SvxXShadowPreview) SvxXShadowPreview::~SvxXShadowPreview() { diff --git a/svx/source/dialog/fntctrl.cxx b/svx/source/dialog/fntctrl.cxx index 72eed9fe4440..a1bb1d4c8289 100644 --- a/svx/source/dialog/fntctrl.cxx +++ b/svx/source/dialog/fntctrl.cxx @@ -20,7 +20,7 @@ #include #include #include -#include +#include #include #include #include @@ -490,7 +490,7 @@ SvxFontPrevWindow::SvxFontPrevWindow(vcl::Window* pParent, WinBits nStyle) Init(); } -extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeSvxFontPrevWindow(vcl::Window *pParent, VclBuilder::stringmap &rMap) +VCL_BUILDER_DECL_FACTORY(SvxFontPrevWindow) { WinBits nWinStyle = 0; OString sBorder = VclBuilder::extractCustomProperty(rMap); diff --git a/svx/source/dialog/fontlb.cxx b/svx/source/dialog/fontlb.cxx index 6b7d1ada0859..625bbd37f7ac 100644 --- a/svx/source/dialog/fontlb.cxx +++ b/svx/source/dialog/fontlb.cxx @@ -18,7 +18,7 @@ */ #include "svx/fontlb.hxx" -#include +#include #include #include #include "svtools/treelistentry.hxx" @@ -89,7 +89,7 @@ SvxFontListBox::SvxFontListBox(vcl::Window* pParent, WinBits nStyle) maEntryFont = maStdFont; } -extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeSvxFontListBox(vcl::Window *pParent, VclBuilder::stringmap &rMap) +VCL_BUILDER_DECL_FACTORY(SvxFontListBox) { WinBits nWinStyle = WB_TABSTOP; OString sBorder = VclBuilder::extractCustomProperty(rMap); diff --git a/svx/source/dialog/frmdirlbox.cxx b/svx/source/dialog/frmdirlbox.cxx index 5c2465df0811..ef87c9f98c10 100644 --- a/svx/source/dialog/frmdirlbox.cxx +++ b/svx/source/dialog/frmdirlbox.cxx @@ -18,12 +18,10 @@ */ #include -#include +#include namespace svx { - - namespace { inline void* lclEnumToVoid( SvxFrameDirection eDirection ) @@ -44,14 +42,14 @@ FrameDirectionListBox::FrameDirectionListBox( vcl::Window* pParent, WinBits nBit { } -extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeFrameDirectionListBox(vcl::Window *pParent, VclBuilder::stringmap &) +VCL_BUILDER_DECL_FACTORY(FrameDirectionListBox) { + (void)rMap; FrameDirectionListBox* pListBox = new FrameDirectionListBox(pParent, WB_LEFT|WB_DROPDOWN|WB_VCENTER|WB_3DLOOK|WB_TABSTOP); pListBox->EnableAutoSize(true); return pListBox; } - void FrameDirectionListBox::InsertEntryValue( const OUString& rString, SvxFrameDirection eDirection, sal_Int32 nPos ) { sal_Int32 nRealPos = InsertEntry( rString, nPos ); diff --git a/svx/source/dialog/frmsel.cxx b/svx/source/dialog/frmsel.cxx index cc38f1ed0849..567bc36b9e13 100644 --- a/svx/source/dialog/frmsel.cxx +++ b/svx/source/dialog/frmsel.cxx @@ -18,7 +18,7 @@ */ #include -#include +#include #include #include @@ -796,8 +796,9 @@ FrameSelector::~FrameSelector() disposeOnce(); } -extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeSvxFrameSelector(vcl::Window *pParent, VclBuilder::stringmap &) +VCL_BUILDER_DECL_FACTORY(SvxFrameSelector) { + (void)rMap; return new FrameSelector(pParent); } diff --git a/svx/source/dialog/graphctl.cxx b/svx/source/dialog/graphctl.cxx index 85b96ece35a9..f1b3a9e51717 100644 --- a/svx/source/dialog/graphctl.cxx +++ b/svx/source/dialog/graphctl.cxx @@ -21,6 +21,7 @@ #include #include #include +#include #include #include #include @@ -73,7 +74,7 @@ GraphCtrl::GraphCtrl( vcl::Window* pParent, WinBits nStyle ) : EnableRTL( false ); } -extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeGraphCtrl(vcl::Window *pParent, VclBuilder::stringmap &rMap) +VCL_BUILDER_DECL_FACTORY(GraphCtrl) { WinBits nWinStyle = 0; OString sBorder = VclBuilder::extractCustomProperty(rMap); diff --git a/svx/source/dialog/imapdlg.cxx b/svx/source/dialog/imapdlg.cxx index 4c8fcdf4e743..295c32f08beb 100644 --- a/svx/source/dialog/imapdlg.cxx +++ b/svx/source/dialog/imapdlg.cxx @@ -52,6 +52,7 @@ #include #include #include +#include #include "dlgunit.hxx" #include @@ -114,10 +115,7 @@ void SvxIMapDlgChildWindow::UpdateIMapDlg( const Graphic& rGraphic, const ImageM pDlg->UpdateLink(rGraphic, pImageMap, pTargetList, pEditingObj); } -extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeStatusBar(vcl::Window *pParent, VclBuilder::stringmap &) -{ - return new StatusBar(pParent); -} +VCL_BUILDER_FACTORY(StatusBar) SvxIMapDlg::SvxIMapDlg(SfxBindings *_pBindings, SfxChildWindow *pCW, vcl::Window* _pParent) : SfxModelessDialog(_pBindings, pCW, _pParent, "ImapDialog", "svx/ui/imapdialog.ui") diff --git a/svx/source/dialog/langbox.cxx b/svx/source/dialog/langbox.cxx index 59d86711ee3b..9311c53b9207 100644 --- a/svx/source/dialog/langbox.cxx +++ b/svx/source/dialog/langbox.cxx @@ -31,7 +31,7 @@ #include #include #include -#include +#include #include using namespace ::com::sun::star::util; @@ -103,8 +103,7 @@ static bool lcl_SeqHasLang( const Sequence< sal_Int16 > & rLangSeq, sal_Int16 nL return i >= 0 && i < nLen; } - -extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeSvxLanguageBox(vcl::Window *pParent, VclBuilder::stringmap &rMap) +VCL_BUILDER_DECL_FACTORY(SvxLanguageBox) { WinBits nBits = WB_LEFT|WB_VCENTER|WB_3DLOOK|WB_TABSTOP; bool bDropdown = VclBuilder::extractDropdown(rMap); @@ -117,7 +116,7 @@ extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeSvxLanguageBox(vcl::Wi return pLanguageBox; } -extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeSvxLanguageComboBox(vcl::Window *pParent, VclBuilder::stringmap &rMap) +VCL_BUILDER_DECL_FACTORY(SvxLanguageComboBox) { WinBits nBits = WB_LEFT|WB_VCENTER|WB_3DLOOK|WB_TABSTOP; bool bDropdown = VclBuilder::extractDropdown(rMap); @@ -130,7 +129,6 @@ extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeSvxLanguageComboBox(vc return pLanguageBox; } - SvxLanguageBoxBase::SvxLanguageBoxBase( bool bCheck ) : m_pSpellUsedLang(NULL) , m_nLangList(SvxLanguageListFlags::EMPTY) diff --git a/svx/source/dialog/measctrl.cxx b/svx/source/dialog/measctrl.cxx index c07f41a580a3..a9c3a9e3f70c 100644 --- a/svx/source/dialog/measctrl.cxx +++ b/svx/source/dialog/measctrl.cxx @@ -23,7 +23,7 @@ #include "svx/measctrl.hxx" #include #include "svx/dlgutil.hxx" -#include +#include #include #include @@ -62,7 +62,7 @@ void SvxXMeasurePreview::Resize() pMeasureObj->SetPoint(aPt2, 1); } -extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeSvxXMeasurePreview(vcl::Window *pParent, VclBuilder::stringmap &rMap) +VCL_BUILDER_DECL_FACTORY(SvxXMeasurePreview) { WinBits nWinStyle = 0; OString sBorder = VclBuilder::extractCustomProperty(rMap); diff --git a/svx/source/dialog/pagectrl.cxx b/svx/source/dialog/pagectrl.cxx index aa9154a90ded..574e32ff0473 100644 --- a/svx/source/dialog/pagectrl.cxx +++ b/svx/source/dialog/pagectrl.cxx @@ -18,7 +18,7 @@ */ #include -#include +#include #include #include #include @@ -100,12 +100,7 @@ void SvxPageWindow::dispose() vcl::Window::dispose(); } -extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeSvxPageWindow(vcl::Window *pParent, VclBuilder::stringmap &) -{ - return new SvxPageWindow(pParent); -} - - +VCL_BUILDER_FACTORY(SvxPageWindow) void SvxPageWindow::Paint(vcl::RenderContext& /*rRenderContext*/, const Rectangle&) { diff --git a/svx/source/dialog/paraprev.cxx b/svx/source/dialog/paraprev.cxx index 523cfe4247cb..ea0b7f02f3f4 100644 --- a/svx/source/dialog/paraprev.cxx +++ b/svx/source/dialog/paraprev.cxx @@ -19,7 +19,7 @@ #include #include -#include +#include #include SvxParaPrevWindow::SvxParaPrevWindow( vcl::Window* pParent, WinBits nBits) : @@ -45,10 +45,7 @@ SvxParaPrevWindow::SvxParaPrevWindow( vcl::Window* pParent, WinBits nBits) : SetBorderStyle( WindowBorderStyle::MONO ); } -extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeSvxParaPrevWindow(vcl::Window *pParent, VclBuilder::stringmap &) -{ - return new SvxParaPrevWindow(pParent, WB_BORDER); -} +VCL_BUILDER_FACTORY_ARGS(SvxParaPrevWindow, WB_BORDER) Size SvxParaPrevWindow::GetOptimalSize() const { diff --git a/svx/source/dialog/rubydialog.cxx b/svx/source/dialog/rubydialog.cxx index b840b4ec3910..9fcc007330ff 100644 --- a/svx/source/dialog/rubydialog.cxx +++ b/svx/source/dialog/rubydialog.cxx @@ -39,6 +39,7 @@ #include #include #include +#include using namespace com::sun::star::uno; using namespace com::sun::star::frame; @@ -799,10 +800,7 @@ void RubyPreview::dispose() vcl::Window::dispose(); } -extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeRubyPreview(vcl::Window *pParent, VclBuilder::stringmap &) -{ - return new RubyPreview(pParent); -} +VCL_BUILDER_FACTORY(RubyPreview) void RubyPreview::Paint( vcl::RenderContext& /*rRenderContext*/, const Rectangle& /* rRect */ ) { @@ -952,9 +950,6 @@ bool RubyEdit::PreNotify( NotifyEvent& rNEvt ) return nHandled; } -extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeRubyEdit(vcl::Window *pParent, VclBuilder::stringmap &) -{ - return new RubyEdit(pParent); -} +VCL_BUILDER_FACTORY(RubyEdit) /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/svx/source/dialog/svxbmpnumvalueset.cxx b/svx/source/dialog/svxbmpnumvalueset.cxx index 1e9953f0dc59..4ad4d87582b4 100644 --- a/svx/source/dialog/svxbmpnumvalueset.cxx +++ b/svx/source/dialog/svxbmpnumvalueset.cxx @@ -34,6 +34,7 @@ #include #include #include +#include #include #include #include @@ -396,10 +397,7 @@ SvxNumValueSet::SvxNumValueSet(vcl::Window* pParent, WinBits nWinBits) { } -extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeSvxNumValueSet(vcl::Window *pParent, VclBuilder::stringmap &) -{ - return new SvxNumValueSet(pParent, WB_TABSTOP); -} +VCL_BUILDER_FACTORY_ARGS(SvxNumValueSet, WB_TABSTOP) void SvxNumValueSet::init(sal_uInt16 nType) { @@ -474,10 +472,7 @@ SvxBmpNumValueSet::SvxBmpNumValueSet(vcl::Window* pParent, WinBits nWinBits) init(); } -extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeSvxBmpNumValueSet(vcl::Window *pParent, VclBuilder::stringmap &) -{ - return new SvxBmpNumValueSet(pParent, WB_TABSTOP); -} +VCL_BUILDER_FACTORY_ARGS(SvxBmpNumValueSet, WB_TABSTOP) void SvxBmpNumValueSet::init() { diff --git a/svx/source/dialog/swframeexample.cxx b/svx/source/dialog/swframeexample.cxx index 1facb436df9c..c21adb0ae809 100644 --- a/svx/source/dialog/swframeexample.cxx +++ b/svx/source/dialog/swframeexample.cxx @@ -18,7 +18,7 @@ */ #include -#include +#include #include #include #include @@ -52,10 +52,7 @@ SvxSwFrameExample::SvxSwFrameExample( vcl::Window *pParent, WinBits nStyle ) : SetMapMode(MAP_PIXEL); } -extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeSvxSwFrameExample(vcl::Window *pParent, VclBuilder::stringmap &) -{ - return new SvxSwFrameExample(pParent, 0); -} +VCL_BUILDER_FACTORY_ARGS(SvxSwFrameExample, 0) Size SvxSwFrameExample::GetOptimalSize() const { diff --git a/svx/source/dialog/txencbox.cxx b/svx/source/dialog/txencbox.cxx index bc16ac104620..c038a5d365d2 100644 --- a/svx/source/dialog/txencbox.cxx +++ b/svx/source/dialog/txencbox.cxx @@ -25,7 +25,7 @@ #if HAVE_FEATURE_DBCONNECTIVITY #include "svx/dbcharsethelper.hxx" #endif -#include +#include #include #include #include @@ -39,7 +39,7 @@ SvxTextEncodingBox::SvxTextEncodingBox( vcl::Window* pParent, WinBits nBits ) m_pEncTable = new SvxTextEncodingTable; } -extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeSvxTextEncodingBox(vcl::Window *pParent, VclBuilder::stringmap &rMap) +VCL_BUILDER_DECL_FACTORY(SvxTextEncodingBox) { WinBits nWinBits = WB_LEFT|WB_VCENTER|WB_3DLOOK|WB_SIMPLEMODE; bool bDropdown = VclBuilder::extractDropdown(rMap); diff --git a/svx/source/form/datanavi.cxx b/svx/source/form/datanavi.cxx index 2eb65f4eea2c..c5712e17d6e1 100644 --- a/svx/source/form/datanavi.cxx +++ b/svx/source/form/datanavi.cxx @@ -42,6 +42,7 @@ #include #include #include +#include #include #include #include @@ -296,10 +297,7 @@ namespace svxform // class XFormsPage - extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeDataTreeListBox(vcl::Window *pParent, VclBuilder::stringmap &) - { - return new DataTreeListBox(static_cast(pParent), WB_BORDER); - } + VCL_BUILDER_FACTORY_ARGS(DataTreeListBox, WB_BORDER) XFormsPage::XFormsPage( vcl::Window* pParent, DataNavigatorWindow* _pNaviWin, DataGroupType _eGroup ) : diff --git a/svx/source/gallery2/galctrl.cxx b/svx/source/gallery2/galctrl.cxx index 90e0f1a069c7..ba1d4b9a899a 100644 --- a/svx/source/gallery2/galctrl.cxx +++ b/svx/source/gallery2/galctrl.cxx @@ -34,6 +34,7 @@ #include "gallery.hrc" #include #include +#include #define GALLERY_BRWBOX_TITLE 1 @@ -47,8 +48,7 @@ GalleryPreview::GalleryPreview(vcl::Window* pParent, WinBits nStyle, GalleryThem InitSettings(); } -extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeGalleryPreview(vcl::Window *pParent, - VclBuilder::stringmap &rMap) +VCL_BUILDER_DECL_FACTORY(GalleryPreview) { WinBits nWinBits = WB_TABSTOP; OString sBorder = VclBuilder::extractCustomProperty(rMap); diff --git a/svx/source/sidebar/possize/SidebarDialControl.cxx b/svx/source/sidebar/possize/SidebarDialControl.cxx index df10da6ed4ec..8f9db397e023 100644 --- a/svx/source/sidebar/possize/SidebarDialControl.cxx +++ b/svx/source/sidebar/possize/SidebarDialControl.cxx @@ -18,7 +18,7 @@ */ #include -#include +#include #include #include @@ -30,10 +30,7 @@ SidebarDialControl::SidebarDialControl (vcl::Window* pParent, WinBits nBits) Init(GetOutputSizePixel()); } -extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeSidebarDialControl(vcl::Window *pParent, VclBuilder::stringmap &) -{ - return new SidebarDialControl(pParent, WB_TABSTOP); -} +VCL_BUILDER_FACTORY_ARGS(SidebarDialControl, WB_TABSTOP) Size SidebarDialControl::GetOptimalSize() const { diff --git a/svx/source/tbxctrls/SvxColorValueSet.cxx b/svx/source/tbxctrls/SvxColorValueSet.cxx index baecf497ec28..ef448a40720a 100644 --- a/svx/source/tbxctrls/SvxColorValueSet.cxx +++ b/svx/source/tbxctrls/SvxColorValueSet.cxx @@ -19,7 +19,7 @@ #include #include -#include +#include #include #include @@ -29,7 +29,7 @@ SvxColorValueSet::SvxColorValueSet(vcl::Window* _pParent, WinBits nWinStyle) SetEdgeBlending(true); } -extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeSvxColorValueSet(vcl::Window *pParent, VclBuilder::stringmap &rMap) +VCL_BUILDER_DECL_FACTORY(SvxColorValueSet) { WinBits nWinBits = WB_TABSTOP; diff --git a/svx/source/tbxctrls/itemwin.cxx b/svx/source/tbxctrls/itemwin.cxx index 02f38d5b10b0..0b575c292cf7 100644 --- a/svx/source/tbxctrls/itemwin.cxx +++ b/svx/source/tbxctrls/itemwin.cxx @@ -27,6 +27,7 @@ #include #include +#include #include @@ -412,12 +413,7 @@ SvxFillTypeBox::SvxFillTypeBox( vcl::Window* pParent, WinBits nBits ) : Show(); } -extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeSvxFillTypeBox(vcl::Window *pParent, VclBuilder::stringmap &) -{ - return new SvxFillTypeBox(pParent); -} - - +VCL_BUILDER_FACTORY(SvxFillTypeBox) bool SvxFillTypeBox::PreNotify( NotifyEvent& rNEvt ) { @@ -493,12 +489,7 @@ SvxFillAttrBox::SvxFillAttrBox( vcl::Window* pParent, WinBits nBits ) : Show(); } -extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeSvxFillAttrBox(vcl::Window *pParent, VclBuilder::stringmap &) -{ - return new SvxFillAttrBox(pParent); -} - - +VCL_BUILDER_FACTORY(SvxFillAttrBox) bool SvxFillAttrBox::PreNotify( NotifyEvent& rNEvt ) { diff --git a/sw/source/ui/chrdlg/drpcps.cxx b/sw/source/ui/chrdlg/drpcps.cxx index cb0f41123051..825c7e26b394 100644 --- a/sw/source/ui/chrdlg/drpcps.cxx +++ b/sw/source/ui/chrdlg/drpcps.cxx @@ -36,6 +36,7 @@ #include #include #include +#include #include #include #include @@ -132,10 +133,7 @@ public: void DrawPrev( const Point& rPt ); }; -extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeSwDropCapsPict(vcl::Window *pParent, VclBuilder::stringmap &) -{ - return new SwDropCapsPict(pParent, WB_BORDER); -} +VCL_BUILDER_FACTORY_ARGS(SwDropCapsPict, WB_BORDER) void SwDropCapsPict::SetText( const OUString& rT ) { diff --git a/sw/source/ui/config/optload.cxx b/sw/source/ui/config/optload.cxx index 5f0cc8b5222c..424760646e80 100644 --- a/sw/source/ui/config/optload.cxx +++ b/sw/source/ui/config/optload.cxx @@ -43,7 +43,7 @@ #include #include -#include +#include #include #include @@ -388,7 +388,7 @@ SwCaptionPreview::SwCaptionPreview( vcl::Window* pParent, WinBits nStyle ) Init(); } -extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeSwCaptionPreview(vcl::Window *pParent, VclBuilder::stringmap &rMap) +VCL_BUILDER_DECL_FACTORY(SwCaptionPreview) { WinBits nBits = 0; OString sBorder = VclBuilder::extractCustomProperty(rMap); @@ -934,7 +934,7 @@ void CaptionComboBox::KeyInput(const KeyEvent& rEvt) SwComboBox::KeyInput(rEvt); } -extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeCaptionComboBox(vcl::Window *pParent, VclBuilder::stringmap &rMap) +VCL_BUILDER_DECL_FACTORY(CaptionComboBox) { WinBits nBits = WB_CLIPCHILDREN|WB_LEFT|WB_VCENTER|WB_3DLOOK; bool bDropdown = VclBuilder::extractDropdown(rMap); diff --git a/sw/source/ui/config/optpage.cxx b/sw/source/ui/config/optpage.cxx index 9d5e019b17ef..fa53537079a2 100644 --- a/sw/source/ui/config/optpage.cxx +++ b/sw/source/ui/config/optpage.cxx @@ -65,6 +65,7 @@ #include #include +#include #include using namespace ::com::sun::star; @@ -1614,10 +1615,7 @@ SwMarkPreview::SwMarkPreview( vcl::Window *pParent, WinBits nWinBits ) : SetMapMode(MAP_PIXEL); } -extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeSwMarkPreview(vcl::Window *pParent, VclBuilder::stringmap &) -{ - return new SwMarkPreview(pParent, 0); -} +VCL_BUILDER_FACTORY_ARGS(SwMarkPreview, 0) SwMarkPreview::~SwMarkPreview() { diff --git a/sw/source/ui/dbui/createaddresslistdialog.cxx b/sw/source/ui/dbui/createaddresslistdialog.cxx index 193e55b1bd7b..a9c122664ca4 100644 --- a/sw/source/ui/dbui/createaddresslistdialog.cxx +++ b/sw/source/ui/dbui/createaddresslistdialog.cxx @@ -24,6 +24,7 @@ #include #include #include +#include #include #include #include @@ -107,8 +108,9 @@ SwAddressControl_Impl::SwAddressControl_Impl(vcl::Window* pParent, WinBits nBits m_pScrollBar->EnableDrag(); } -extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeSwAddressControlImpl(vcl::Window *pParent, VclBuilder::stringmap &) +VCL_BUILDER_DECL_FACTORY(SwAddressControlImpl) { + (void)rMap; return new SwAddressControl_Impl(pParent, WB_BORDER | WB_DIALOGCONTROL); } diff --git a/sw/source/ui/dbui/mmaddressblockpage.cxx b/sw/source/ui/dbui/mmaddressblockpage.cxx index 35214f509d23..2c25df2e318d 100644 --- a/sw/source/ui/dbui/mmaddressblockpage.cxx +++ b/sw/source/ui/dbui/mmaddressblockpage.cxx @@ -24,6 +24,7 @@ #include #include #include +#include #include #include #include @@ -845,10 +846,7 @@ public: virtual Size GetOptimalSize() const SAL_OVERRIDE; }; -extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeSwAssignFieldsControl(vcl::Window *pParent, VclBuilder::stringmap &) -{ - return new SwAssignFieldsControl(pParent, WB_BORDER); -} +VCL_BUILDER_FACTORY_ARGS(SwAssignFieldsControl, WB_BORDER) SwAssignFieldsControl::SwAssignFieldsControl(vcl::Window* pParent, WinBits nBits) : Control(pParent, nBits | WB_DIALOGCONTROL | WB_TABSTOP | WB_DIALOGCONTROL), @@ -1288,8 +1286,7 @@ void DDListBox::dispose() SvTreeListBox::dispose(); } - -extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeDDListBox(vcl::Window *pParent, VclBuilder::stringmap &rMap) +VCL_BUILDER_DECL_FACTORY(DDListBox) { WinBits nWinStyle = WB_TABSTOP; OString sBorder = VclBuilder::extractCustomProperty(rMap); @@ -1351,7 +1348,7 @@ Size AddressMultiLineEdit::GetOptimalSize() const return LogicToPixel(Size(160, 60), MAP_APPFONT); } -extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeAddressMultiLineEdit(vcl::Window *pParent, VclBuilder::stringmap &rMap) +VCL_BUILDER_DECL_FACTORY(AddressMultiLineEdit) { WinBits nWinStyle = WB_LEFT|WB_TABSTOP; OString sBorder = VclBuilder::extractCustomProperty(rMap); diff --git a/sw/source/ui/envelp/envlop1.cxx b/sw/source/ui/envelp/envlop1.cxx index e6072f718899..b552d0357852 100644 --- a/sw/source/ui/envelp/envlop1.cxx +++ b/sw/source/ui/envelp/envlop1.cxx @@ -19,7 +19,7 @@ #include "dbmgr.hxx" #include -#include +#include #include #include @@ -57,10 +57,7 @@ Size SwEnvPreview::GetOptimalSize() const return LogicToPixel(Size(84 , 63), MAP_APPFONT); } -extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeSwEnvPreview(vcl::Window *pParent, VclBuilder::stringmap &) -{ - return new SwEnvPreview(pParent, 0); -} +VCL_BUILDER_FACTORY_ARGS(SwEnvPreview, 0) void SwEnvPreview::DataChanged( const DataChangedEvent& rDCEvt ) { diff --git a/sw/source/ui/envelp/labfmt.cxx b/sw/source/ui/envelp/labfmt.cxx index be2171bdde8e..6801e24d3a4b 100644 --- a/sw/source/ui/envelp/labfmt.cxx +++ b/sw/source/ui/envelp/labfmt.cxx @@ -20,6 +20,7 @@ #include #include #include +#include #include @@ -84,10 +85,7 @@ Size SwLabPreview::GetOptimalSize() const return LogicToPixel(Size(146 , 161), MapMode(MAP_APPFONT)); } -extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeSwLabPreview(vcl::Window *pParent, VclBuilder::stringmap &) -{ - return new SwLabPreview(pParent); -} +VCL_BUILDER_FACTORY(SwLabPreview) void SwLabPreview::Paint(vcl::RenderContext& /*rRenderContext*/, const Rectangle &) { diff --git a/sw/source/ui/fldui/FldRefTreeListBox.cxx b/sw/source/ui/fldui/FldRefTreeListBox.cxx index c04603c02aa7..c84b5c45e73b 100644 --- a/sw/source/ui/fldui/FldRefTreeListBox.cxx +++ b/sw/source/ui/fldui/FldRefTreeListBox.cxx @@ -20,7 +20,7 @@ #include #include -#include +#include #include SwFldRefTreeListBox::SwFldRefTreeListBox(vcl::Window* pParent, WinBits nStyle) @@ -28,7 +28,7 @@ SwFldRefTreeListBox::SwFldRefTreeListBox(vcl::Window* pParent, WinBits nStyle) { } -extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeSwFldRefTreeListBox(vcl::Window *pParent, VclBuilder::stringmap &rMap) +VCL_BUILDER_DECL_FACTORY(SwFldRefTreeListBox) { WinBits nWinStyle = WB_TABSTOP; OString sBorder = VclBuilder::extractCustomProperty(rMap); diff --git a/sw/source/ui/fldui/fldvar.cxx b/sw/source/ui/fldui/fldvar.cxx index 06774c80a89d..8da46a400a26 100644 --- a/sw/source/ui/fldui/fldvar.cxx +++ b/sw/source/ui/fldui/fldvar.cxx @@ -19,6 +19,7 @@ #include #include +#include #include #include #include @@ -1262,7 +1263,7 @@ SelectionListBox::SelectionListBox(vcl::Window* pParent, WinBits nStyle) { } -extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeSelectionListBox(vcl::Window *pParent, VclBuilder::stringmap &rMap) +VCL_BUILDER_DECL_FACTORY(SelectionListBox) { WinBits nBits = WB_LEFT|WB_VCENTER|WB_3DLOOK; diff --git a/sw/source/ui/frmdlg/column.cxx b/sw/source/ui/frmdlg/column.cxx index e7e003356a7d..d45c5c4ca3ed 100644 --- a/sw/source/ui/frmdlg/column.cxx +++ b/sw/source/ui/frmdlg/column.cxx @@ -36,6 +36,7 @@ #include #include #include +#include #include #include @@ -1425,9 +1426,6 @@ void ColumnValueSet::DataChanged( const DataChangedEvent& rDCEvt ) ValueSet::DataChanged( rDCEvt ); } -extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeColumnValueSet(vcl::Window *pParent, VclBuilder::stringmap &) -{ - return new ColumnValueSet(pParent); -} +VCL_BUILDER_FACTORY(ColumnValueSet) /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/sw/source/ui/frmdlg/frmpage.cxx b/sw/source/ui/frmdlg/frmpage.cxx index 7da73f230dd8..17e23f516816 100644 --- a/sw/source/ui/frmdlg/frmpage.cxx +++ b/sw/source/ui/frmdlg/frmpage.cxx @@ -68,6 +68,7 @@ #include #include #include +#include #include using namespace ::com::sun::star; @@ -2660,10 +2661,7 @@ Size BmpWindow::GetOptimalSize() const return LogicToPixel(Size(127 , 66), MapMode(MAP_APPFONT)); } -extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeBmpWindow(vcl::Window *pParent, VclBuilder::stringmap &) -{ - return new BmpWindow(pParent, 0); -} +VCL_BUILDER_FACTORY_ARGS(BmpWindow, 0) void BmpWindow::Paint( vcl::RenderContext& /*rRenderContext*/, const Rectangle& ) { diff --git a/sw/source/ui/index/cnttab.cxx b/sw/source/ui/index/cnttab.cxx index 9bdf2e16af2c..2bac0f544ae7 100644 --- a/sw/source/ui/index/cnttab.cxx +++ b/sw/source/ui/index/cnttab.cxx @@ -23,6 +23,7 @@ #include #include #include +#include #include #include #include @@ -1758,7 +1759,7 @@ void SwIdxTreeListBox::dispose() SvTreeListBox::dispose(); } -extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeSwIdxTreeListBox(vcl::Window *pParent, VclBuilder::stringmap &rMap) +VCL_BUILDER_DECL_FACTORY(SwIdxTreeListBox) { WinBits nWinStyle = WB_TABSTOP; OString sBorder = VclBuilder::extractCustomProperty(rMap); @@ -2736,10 +2737,7 @@ SwTokenWindow::SwTokenWindow(vcl::Window* pParent) m_pRightScrollWin->SetClickHdl(aLink); } -extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeSwTokenWindow(vcl::Window *pParent, VclBuilder::stringmap &) -{ - return new SwTokenWindow(pParent); -} +VCL_BUILDER_FACTORY(SwTokenWindow) void SwTokenWindow::setAllocation(const Size &rAllocation) { diff --git a/sw/source/ui/misc/bookmark.cxx b/sw/source/ui/misc/bookmark.cxx index 5eaf63a98ddb..f3c55975a86a 100644 --- a/sw/source/ui/misc/bookmark.cxx +++ b/sw/source/ui/misc/bookmark.cxx @@ -21,6 +21,7 @@ #include #include #include +#include #include "view.hxx" #include "basesh.hxx" @@ -238,9 +239,6 @@ bool BookmarkCombo::PreNotify( NotifyEvent& rNEvt ) return nHandled; } -extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeBookmarkCombo(vcl::Window* pParent, VclBuilder::stringmap &) -{ - return new BookmarkCombo(pParent, 0); -} +VCL_BUILDER_FACTORY_ARGS(BookmarkCombo, 0) /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/sw/source/ui/misc/glosbib.cxx b/sw/source/ui/misc/glosbib.cxx index 98953c089ab8..b1ec21dce153 100644 --- a/sw/source/ui/misc/glosbib.cxx +++ b/sw/source/ui/misc/glosbib.cxx @@ -21,6 +21,7 @@ #include #include #include +#include #include #include #include @@ -407,12 +408,9 @@ void FEdit::KeyInput( const KeyEvent& rKEvent ) Edit::KeyInput( rKEvent ); } -extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeFEdit(vcl::Window *pParent, VclBuilder::stringmap &) -{ - return new FEdit(pParent); -} +VCL_BUILDER_FACTORY(FEdit) -void SwGlossaryGroupTLB::RequestHelp( const HelpEvent& rHEvt ) +void SwGlossaryGroupTLB::RequestHelp( const HelpEvent& rHEvt ) { Point aPos( ScreenToOutputPixel( rHEvt.GetMousePosPixel() )); SvTreeListEntry* pEntry = GetEntry( aPos ); @@ -441,9 +439,6 @@ void SwGlossaryGroupTLB::RequestHelp( const HelpEvent& rHEvt ) } } -extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeSwGlossaryGroupTLB(vcl::Window *pParent, VclBuilder::stringmap &) -{ - return new SwGlossaryGroupTLB(pParent); -} +VCL_BUILDER_FACTORY(SwGlossaryGroupTLB) /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/sw/source/ui/misc/glossary.cxx b/sw/source/ui/misc/glossary.cxx index 1f7a6ffb72cf..388e7e5b6218 100644 --- a/sw/source/ui/misc/glossary.cxx +++ b/sw/source/ui/misc/glossary.cxx @@ -22,6 +22,7 @@ #include #include #include +#include #include #include #include @@ -852,10 +853,7 @@ Size SwGlTreeListBox::GetOptimalSize() const return LogicToPixel(Size(212, 84), MapMode(MAP_APPFONT)); } -extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeSwGlTreeListBox(vcl::Window *pParent, VclBuilder::stringmap &) -{ - return new SwGlTreeListBox(pParent, WB_BORDER | WB_TABSTOP); -} +VCL_BUILDER_FACTORY_ARGS(SwGlTreeListBox, WB_BORDER | WB_TABSTOP) void SwGlTreeListBox::Clear() { diff --git a/sw/source/ui/misc/outline.cxx b/sw/source/ui/misc/outline.cxx index 83c0e9294491..94a6f2777beb 100644 --- a/sw/source/ui/misc/outline.cxx +++ b/sw/source/ui/misc/outline.cxx @@ -21,6 +21,7 @@ #include #include #include +#include #include #include @@ -918,10 +919,7 @@ static long lcl_DrawGraphic(vcl::RenderContext* pVDev, const SwNumFmt &rFmt, lon return nRet; } -extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeNumberingPreview(vcl::Window *pParent, VclBuilder::stringmap &) -{ - return new NumberingPreview(pParent); -} +VCL_BUILDER_FACTORY(NumberingPreview) // paint numbering's preview void NumberingPreview::Paint( vcl::RenderContext& /*rRenderContext*/, const Rectangle& /*rRect*/ ) diff --git a/sw/source/ui/table/tautofmt.cxx b/sw/source/ui/table/tautofmt.cxx index c1e10cff7684..3332023cd12f 100644 --- a/sw/source/ui/table/tautofmt.cxx +++ b/sw/source/ui/table/tautofmt.cxx @@ -22,6 +22,7 @@ #include #include #include +#include #include #include @@ -532,7 +533,7 @@ AutoFmtPreview::AutoFmtPreview(vcl::Window* pParent, WinBits nStyle) : Init(); } -extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeAutoFmtPreview(vcl::Window *pParent, VclBuilder::stringmap &rMap) +VCL_BUILDER_DECL_FACTORY(AutoFmtPreview) { WinBits nWinStyle = 0; OString sBorder = VclBuilder::extractCustomProperty(rMap); diff --git a/sw/source/uibase/cctrl/actctrl.cxx b/sw/source/uibase/cctrl/actctrl.cxx index 04f9932c3d83..119dbb39c3af 100644 --- a/sw/source/uibase/cctrl/actctrl.cxx +++ b/sw/source/uibase/cctrl/actctrl.cxx @@ -18,7 +18,7 @@ */ #include -#include +#include #include "actctrl.hxx" void NumEditAction::Action() @@ -62,7 +62,7 @@ void ReturnActionEdit::KeyInput( const KeyEvent& rEvt) Edit::KeyInput(rEvt); } -extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeReturnActionEdit(vcl::Window *pParent, VclBuilder::stringmap &rMap) +VCL_BUILDER_DECL_FACTORY(ReturnActionEdit) { VclBuilder::ensureDefaultWidthChars(rMap); return new ReturnActionEdit(pParent, WB_LEFT|WB_VCENTER|WB_BORDER|WB_3DLOOK); diff --git a/sw/source/uibase/dbui/dbtree.cxx b/sw/source/uibase/dbui/dbtree.cxx index 2d893cb32aaa..0e9fa0d0f28e 100644 --- a/sw/source/uibase/dbui/dbtree.cxx +++ b/sw/source/uibase/dbui/dbtree.cxx @@ -41,7 +41,7 @@ #include #include #include -#include +#include #include #include @@ -180,7 +180,7 @@ SwDBTreeList::SwDBTreeList(vcl::Window *pParent, WinBits nStyle) InitTreeList(); } -extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeSwDBTreeList(vcl::Window *pParent, VclBuilder::stringmap &rMap) +VCL_BUILDER_DECL_FACTORY(SwDBTreeList) { WinBits nStyle = WB_TABSTOP; OString sBorder = VclBuilder::extractCustomProperty(rMap); diff --git a/sw/source/uibase/dbui/mailmergehelper.cxx b/sw/source/uibase/dbui/mailmergehelper.cxx index c342034c5269..d827f70e472f 100644 --- a/sw/source/uibase/dbui/mailmergehelper.cxx +++ b/sw/source/uibase/dbui/mailmergehelper.cxx @@ -37,6 +37,7 @@ #include #include #include +#include #include @@ -206,7 +207,7 @@ void SwAddressPreview::dispose() vcl::Window::dispose(); } -extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeSwAddressPreview(vcl::Window *pParent, VclBuilder::stringmap &rMap) +VCL_BUILDER_DECL_FACTORY(SwAddressPreview) { WinBits nWinStyle = WB_TABSTOP; OString sBorder = VclBuilder::extractCustomProperty(rMap); diff --git a/sw/source/uibase/frmdlg/colex.cxx b/sw/source/uibase/frmdlg/colex.cxx index 829457655579..790f0b34d152 100644 --- a/sw/source/uibase/frmdlg/colex.cxx +++ b/sw/source/uibase/frmdlg/colex.cxx @@ -32,6 +32,7 @@ #include #include #include +#include #include #include #include "colex.hxx" @@ -314,10 +315,7 @@ void SwColExample::DrawPage( const Point& rOrg, } } -extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeSwColExample(vcl::Window *pParent, VclBuilder::stringmap &) -{ - return new SwColExample(pParent); -} +VCL_BUILDER_FACTORY(SwColExample) SwColumnOnlyExample::SwColumnOnlyExample(vcl::Window* pParent) : Window(pParent) @@ -343,10 +341,7 @@ SwColumnOnlyExample::SwColumnOnlyExample(vcl::Window* pParent) SetMapMode( aMapMode ); } -extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeSwColumnOnlyExample(vcl::Window *pParent, VclBuilder::stringmap &) -{ - return new SwColumnOnlyExample(pParent); -} +VCL_BUILDER_FACTORY(SwColumnOnlyExample) void SwColumnOnlyExample::Paint( vcl::RenderContext& /*rRenderContext*/, const Rectangle& /*rRect*/ ) { @@ -613,9 +608,6 @@ void SwPageGridExample::UpdateExample( const SfxItemSet& rSet ) SwPageExample::UpdateExample(rSet); } -extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeSwPageGridExample(vcl::Window *pParent, VclBuilder::stringmap &) -{ - return new SwPageGridExample(pParent); -} +VCL_BUILDER_FACTORY(SwPageGridExample) /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/sw/source/uibase/misc/numberingtypelistbox.cxx b/sw/source/uibase/misc/numberingtypelistbox.cxx index 8f8264e0bc3c..30b6b05a6640 100644 --- a/sw/source/uibase/misc/numberingtypelistbox.cxx +++ b/sw/source/uibase/misc/numberingtypelistbox.cxx @@ -25,6 +25,7 @@ #include #include #include +#include #include @@ -54,8 +55,9 @@ bool SwNumberingTypeListBox::set_property(const OString &rKey, const OString &rV return true; } -extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeSwNumberingTypeListBox(vcl::Window *pParent, VclBuilder::stringmap &) +VCL_BUILDER_DECL_FACTORY(SwNumberingTypeListBox) { + (void)rMap; SwNumberingTypeListBox *pListBox = new SwNumberingTypeListBox(pParent, WB_LEFT|WB_DROPDOWN|WB_VCENTER|WB_3DLOOK|WB_TABSTOP); pListBox->EnableAutoSize(true); return pListBox; diff --git a/sw/source/uibase/utlui/condedit.cxx b/sw/source/uibase/utlui/condedit.cxx index dbf9da568af8..907ac1f4d5e0 100644 --- a/sw/source/uibase/utlui/condedit.cxx +++ b/sw/source/uibase/utlui/condedit.cxx @@ -21,7 +21,7 @@ #include #include -#include +#include using namespace ::svx; using namespace ::com::sun::star::uno; @@ -34,7 +34,7 @@ ConditionEdit::ConditionEdit(vcl::Window* pParent, WinBits nStyle) { } -extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeConditionEdit(vcl::Window *pParent, VclBuilder::stringmap &rMap) +VCL_BUILDER_DECL_FACTORY(ConditionEdit) { VclBuilder::ensureDefaultWidthChars(rMap); return new ConditionEdit(pParent, WB_LEFT|WB_VCENTER|WB_BORDER|WB_3DLOOK); diff --git a/sw/source/uibase/utlui/numfmtlb.cxx b/sw/source/uibase/utlui/numfmtlb.cxx index 56d87e6edb49..32bab7f225b7 100644 --- a/sw/source/uibase/utlui/numfmtlb.cxx +++ b/sw/source/uibase/utlui/numfmtlb.cxx @@ -28,6 +28,7 @@ #include #include #include +#include #include #include #include @@ -68,7 +69,7 @@ NumFormatListBox::NumFormatListBox(vcl::Window* pWin, WinBits nStyle) : Init(css::util::NumberFormat::NUMBER, true); } -extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeNumFormatListBox(vcl::Window *pParent, VclBuilder::stringmap &rMap) +VCL_BUILDER_DECL_FACTORY(NumFormatListBox) { WinBits nBits = WB_LEFT|WB_VCENTER|WB_3DLOOK; -- cgit v1.2.3