diff options
author | Michael Meeks <michael.meeks@collabora.com> | 2015-05-11 13:42:10 +0100 |
---|---|---|
committer | Michael Meeks <michael.meeks@collabora.com> | 2015-05-11 13:57:27 +0100 |
commit | ceb6f473837261f2a6e43e028ce9da3daccc2f6c (patch) | |
tree | a1d3c72cfa773b7cf2c54d4c66c184a4146fa679 /sw/source/ui | |
parent | 3fa5ac20a003d2eb0b718a98eb2217749e3133da (diff) |
tdf#91052 - more macros for 'make' constructors.
Change-Id: Iece86485c52041b66cde91d7fbc772db16d90a93
Diffstat (limited to 'sw/source/ui')
-rw-r--r-- | sw/source/ui/chrdlg/drpcps.cxx | 6 | ||||
-rw-r--r-- | sw/source/ui/config/optload.cxx | 6 | ||||
-rw-r--r-- | sw/source/ui/config/optpage.cxx | 6 | ||||
-rw-r--r-- | sw/source/ui/dbui/createaddresslistdialog.cxx | 4 | ||||
-rw-r--r-- | sw/source/ui/dbui/mmaddressblockpage.cxx | 11 | ||||
-rw-r--r-- | sw/source/ui/envelp/envlop1.cxx | 7 | ||||
-rw-r--r-- | sw/source/ui/envelp/labfmt.cxx | 6 | ||||
-rw-r--r-- | sw/source/ui/fldui/FldRefTreeListBox.cxx | 4 | ||||
-rw-r--r-- | sw/source/ui/fldui/fldvar.cxx | 3 | ||||
-rw-r--r-- | sw/source/ui/frmdlg/column.cxx | 6 | ||||
-rw-r--r-- | sw/source/ui/frmdlg/frmpage.cxx | 6 | ||||
-rw-r--r-- | sw/source/ui/index/cnttab.cxx | 8 | ||||
-rw-r--r-- | sw/source/ui/misc/bookmark.cxx | 6 | ||||
-rw-r--r-- | sw/source/ui/misc/glosbib.cxx | 13 | ||||
-rw-r--r-- | sw/source/ui/misc/glossary.cxx | 6 | ||||
-rw-r--r-- | sw/source/ui/misc/outline.cxx | 6 | ||||
-rw-r--r-- | sw/source/ui/table/tautofmt.cxx | 3 |
17 files changed, 41 insertions, 66 deletions
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 <sfx2/objsh.hxx> #include <editeng/svxfont.hxx> #include <vcl/print.hxx> +#include <vcl/builderfactory.hxx> #include <sfx2/printer.hxx> #include <com/sun/star/i18n/ScriptType.hpp> #include <editeng/scripttypeitem.hxx> @@ -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 <svtools/insdlg.hxx> #include <svtools/treelistentry.hxx> -#include <vcl/builder.hxx> +#include <vcl/builderfactory.hxx> #include <vcl/settings.hxx> #include <comphelper/classids.hxx> @@ -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 <svx/strarray.hxx> #include <vcl/settings.hxx> +#include <vcl/builderfactory.hxx> #include <vcl/svapp.hxx> 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 <comphelper/string.hxx> #include <vcl/scrbar.hxx> #include <vcl/msgbox.hxx> +#include <vcl/builderfactory.hxx> #include <svtools/controldims.hrc> #include <unotools/pathoptions.hxx> #include <sfx2/filedlghelper.hxx> @@ -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 <vcl/layout.hxx> #include <vcl/txtattr.hxx> #include <vcl/xtextedt.hxx> +#include <vcl/builderfactory.hxx> #include <mmconfigitem.hxx> #include <com/sun/star/container/XNameAccess.hpp> #include <com/sun/star/sdbcx/XColumnsSupplier.hpp> @@ -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 <sfx2/app.hxx> -#include <vcl/builder.hxx> +#include <vcl/builderfactory.hxx> #include <vcl/msgbox.hxx> #include <vcl/settings.hxx> @@ -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 <tools/poly.hxx> #include <vcl/layout.hxx> #include <vcl/settings.hxx> +#include <vcl/builderfactory.hxx> #include <viewopt.hxx> @@ -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 <FldRefTreeListBox.hxx> #include <helpid.h> -#include <vcl/builder.hxx> +#include <vcl/builderfactory.hxx> #include <vcl/help.hxx> 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 <swtypes.hxx> #include <sfx2/linkmgr.hxx> +#include <vcl/builderfactory.hxx> #include <IDocumentFieldsAccess.hxx> #include <usrfld.hxx> #include <docufld.hxx> @@ -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 <sfx2/dispatch.hxx> #include <vcl/msgbox.hxx> #include <vcl/settings.hxx> +#include <vcl/builderfactory.hxx> #include <swmodule.hxx> #include <sal/macros.h> @@ -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 <com/sun/star/ui/dialogs/XFilePickerControlAccess.hpp> #include <com/sun/star/ui/dialogs/ExtendedFilePickerElementIds.hpp> #include <vcl/graphicfilter.hxx> +#include <vcl/builderfactory.hxx> #include <boost/scoped_ptr.hpp> 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 <rsc/rscsfx.hxx> #include <vcl/msgbox.hxx> #include <vcl/help.hxx> +#include <vcl/builderfactory.hxx> #include <svl/stritem.hxx> #include <svl/urihelper.hxx> #include <unotools/pathoptions.hxx> @@ -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 <sfx2/request.hxx> #include <svl/stritem.hxx> #include <vcl/msgbox.hxx> +#include <vcl/builderfactory.hxx> #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 <tools/stream.hxx> #include <vcl/msgbox.hxx> #include <vcl/help.hxx> +#include <vcl/builderfactory.hxx> #include <unotools/transliterationwrapper.hxx> #include <unotools/tempfile.hxx> #include <unotools/pathoptions.hxx> @@ -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 <vcl/menu.hxx> #include <vcl/layout.hxx> #include <vcl/help.hxx> +#include <vcl/builderfactory.hxx> #include <svl/stritem.hxx> #include <unotools/pathoptions.hxx> #include <unotools/lingucfg.hxx> @@ -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 <vcl/menu.hxx> #include <vcl/msgbox.hxx> #include <vcl/settings.hxx> +#include <vcl/builderfactory.hxx> #include <sfx2/tabdlg.hxx> #include <editeng/brushitem.hxx> @@ -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 <vcl/msgbox.hxx> #include <vcl/svapp.hxx> #include <vcl/settings.hxx> +#include <vcl/builderfactory.hxx> #include <svl/zforlist.hxx> #include <com/sun/star/lang/XMultiServiceFactory.hpp> @@ -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); |