summaryrefslogtreecommitdiff
path: root/svtools
diff options
context:
space:
mode:
authorMichael Meeks <michael.meeks@collabora.com>2015-05-11 09:35:06 +0100
committerMichael Meeks <michael.meeks@collabora.com>2015-05-11 13:07:45 +0100
commitb01554bcdaca076f900c25b672fd691dbe76c9db (patch)
treed9c542e48970d841f39c6b429ed418f8995ffc1a /svtools
parentfa9eb2512983b20510be3681fad379573b58fc72 (diff)
tdf#91052 - more macros for 'make' constructors.
Change-Id: Ic7ff127e2793993f9dcf1018f8d5ed4f2858a2c4
Diffstat (limited to 'svtools')
-rw-r--r--svtools/source/contnr/DocumentInfoPreview.cxx6
-rw-r--r--svtools/source/contnr/fileview.cxx4
-rw-r--r--svtools/source/contnr/simptabl.cxx9
-rw-r--r--svtools/source/contnr/svtabbx.cxx5
-rw-r--r--svtools/source/contnr/treelistbox.cxx4
-rw-r--r--svtools/source/control/ctrlbox.cxx12
-rw-r--r--svtools/source/control/fmtfield.cxx8
-rw-r--r--svtools/source/control/inettbc.cxx5
-rw-r--r--svtools/source/control/urlcontrol.cxx6
-rw-r--r--svtools/source/control/valueset.cxx4
-rw-r--r--svtools/source/edit/editsyntaxhighlighter.cxx7
11 files changed, 29 insertions, 41 deletions
diff --git a/svtools/source/contnr/DocumentInfoPreview.cxx b/svtools/source/contnr/DocumentInfoPreview.cxx
index 8efa8de2847f..f94ee83e6585 100644
--- a/svtools/source/contnr/DocumentInfoPreview.cxx
+++ b/svtools/source/contnr/DocumentInfoPreview.cxx
@@ -32,6 +32,7 @@
#include <vcl/builder.hxx>
#include <vcl/txtattr.hxx>
#include <vcl/settings.hxx>
+#include <vcl/builderfactory.hxx>
#include <tools/datetime.hxx>
#include <tools/urlobj.hxx>
#include <unotools/pathoptions.hxx>
@@ -65,10 +66,7 @@ void ODocumentInfoPreview::dispose()
Window::dispose();
}
-extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeODocumentInfoPreview(vcl::Window *pParent, VclBuilder::stringmap&)
-{
- return new ODocumentInfoPreview(pParent, WB_BORDER | WB_READONLY);
-}
+VCL_BUILDER_FACTORY_ARGS(ODocumentInfoPreview, WB_BORDER | WB_READONLY)
void ODocumentInfoPreview::Resize() {
m_pEditWin->SetPosSizePixel(Point(0, 0), GetOutputSize());
diff --git a/svtools/source/contnr/fileview.cxx b/svtools/source/contnr/fileview.cxx
index 0c13c548e5e0..60e53181b427 100644
--- a/svtools/source/contnr/fileview.cxx
+++ b/svtools/source/contnr/fileview.cxx
@@ -66,6 +66,7 @@
#include <osl/conditn.hxx>
#include <salhelper/timer.hxx>
#include <vcl/svapp.hxx>
+#include <vcl/builderfactory.hxx>
#include <unotools/ucbhelper.hxx>
#include <unotools/intlwrapper.hxx>
#include <unotools/syslocale.hxx>
@@ -1120,8 +1121,7 @@ void SvtFileView::dispose()
Control::dispose();
}
-extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeSvtFileView(vcl::Window *pParent,
-VclBuilder::stringmap &rMap)
+VCL_BUILDER_DECL_FACTORY(SvtFileView)
{
WinBits nBits = WB_CLIPCHILDREN|WB_LEFT|WB_VCENTER|WB_3DLOOK;
diff --git a/svtools/source/contnr/simptabl.cxx b/svtools/source/contnr/simptabl.cxx
index 6a42aa3341e3..87d173f2639f 100644
--- a/svtools/source/contnr/simptabl.cxx
+++ b/svtools/source/contnr/simptabl.cxx
@@ -21,7 +21,7 @@
#include <svtools/simptabl.hxx>
#include <svtools/svlbitm.hxx>
#include <svtools/treelistentry.hxx>
-#include <vcl/builder.hxx>
+#include <vcl/builderfactory.hxx>
#include <vcl/svapp.hxx>
#include <vcl/settings.hxx>
@@ -42,11 +42,8 @@ void SvSimpleTableContainer::dispose()
Control::dispose();
}
-extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeSvSimpleTableContainer(vcl::Window *pParent,
- VclBuilder::stringmap &)
-{
- return new SvSimpleTableContainer(pParent, WB_TABSTOP | WB_DIALOGCONTROL | WB_BORDER);
-}
+VCL_BUILDER_FACTORY_ARGS(SvSimpleTableContainer,
+ WB_TABSTOP | WB_DIALOGCONTROL | WB_BORDER)
void SvSimpleTableContainer::SetTable(SvSimpleTable* pTable)
{
diff --git a/svtools/source/contnr/svtabbx.cxx b/svtools/source/contnr/svtabbx.cxx
index 931ca8a5f422..0bcd09b28a19 100644
--- a/svtools/source/contnr/svtabbx.cxx
+++ b/svtools/source/contnr/svtabbx.cxx
@@ -23,7 +23,7 @@
#include <svtools/svlbitm.hxx>
#include <svtools/svtools.hrc>
#include <svtools/treelistentry.hxx>
-#include <vcl/builder.hxx>
+#include <vcl/builderfactory.hxx>
#include <com/sun/star/accessibility/AccessibleStateType.hpp>
#include <com/sun/star/accessibility/AccessibleEventId.hpp>
#include "svtaccessiblefactory.hxx"
@@ -98,8 +98,7 @@ SvTabListBox::SvTabListBox( vcl::Window* pParent, WinBits nBits )
SetHighlightRange(); // select full width
}
-extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeSvTabListBox(vcl::Window *pParent,
- VclBuilder::stringmap &rMap)
+VCL_BUILDER_DECL_FACTORY(SvTabListBox)
{
WinBits nWinStyle = WB_TABSTOP;
OString sBorder = VclBuilder::extractCustomProperty(rMap);
diff --git a/svtools/source/contnr/treelistbox.cxx b/svtools/source/contnr/treelistbox.cxx
index 9c2e99231537..097adedd94f0 100644
--- a/svtools/source/contnr/treelistbox.cxx
+++ b/svtools/source/contnr/treelistbox.cxx
@@ -28,7 +28,7 @@
#include <vcl/svapp.hxx>
#include <vcl/accel.hxx>
#include <vcl/i18nhelp.hxx>
-#include <vcl/builder.hxx>
+#include <vcl/builderfactory.hxx>
#include <vcl/settings.hxx>
#include <sot/formats.hxx>
#include <unotools/accessiblestatesethelper.hxx>
@@ -434,7 +434,7 @@ SvTreeListBox::SvTreeListBox(vcl::Window* pParent, const ResId& rResId) :
SetSublistOpenWithLeftRight();
}
-extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeSvTreeListBox(vcl::Window *pParent, VclBuilder::stringmap &rMap)
+VCL_BUILDER_DECL_FACTORY(SvTreeListBox)
{
WinBits nWinStyle = WB_TABSTOP;
OString sBorder = VclBuilder::extractCustomProperty(rMap);
diff --git a/svtools/source/control/ctrlbox.cxx b/svtools/source/control/ctrlbox.cxx
index 8e397e4de9cc..2be6e63e770f 100644
--- a/svtools/source/control/ctrlbox.cxx
+++ b/svtools/source/control/ctrlbox.cxx
@@ -21,7 +21,7 @@
#include <i18nutil/unicode.hxx>
#include <tools/stream.hxx>
-#include <vcl/builder.hxx>
+#include <vcl/builderfactory.hxx>
#include <vcl/svapp.hxx>
#include <vcl/field.hxx>
#include <vcl/helper.hxx>
@@ -104,7 +104,7 @@ ColorListBox::ColorListBox( vcl::Window* pParent, const ResId& rResId ) :
SetEdgeBlending(true);
}
-extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeColorListBox(vcl::Window *pParent, VclBuilder::stringmap &rMap)
+VCL_BUILDER_DECL_FACTORY(ColorListBox)
{
bool bDropdown = VclBuilder::extractDropdown(rMap);
WinBits nWinBits = WB_LEFT|WB_VCENTER|WB_3DLOOK|WB_TABSTOP;
@@ -736,7 +736,7 @@ LineListBox::LineListBox( vcl::Window* pParent, WinBits nWinStyle ) :
ImplInit();
}
-extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeLineListBox(vcl::Window *pParent, VclBuilder::stringmap &rMap)
+VCL_BUILDER_DECL_FACTORY(LineListBox)
{
bool bDropdown = VclBuilder::extractDropdown(rMap);
WinBits nWinBits = WB_LEFT|WB_VCENTER|WB_3DLOOK|WB_TABSTOP;
@@ -939,7 +939,7 @@ FontNameBox::FontNameBox( vcl::Window* pParent, WinBits nWinStyle ) :
InitFontMRUEntriesFile();
}
-extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeFontNameBox(vcl::Window *pParent, VclBuilder::stringmap &rMap)
+VCL_BUILDER_DECL_FACTORY(FontNameBox)
{
bool bDropdown = VclBuilder::extractDropdown(rMap);
WinBits nWinBits = WB_LEFT|WB_VCENTER|WB_3DLOOK|WB_TABSTOP;
@@ -1327,7 +1327,7 @@ Size FontStyleBox::GetOptimalSize() const
return ComboBox::GetOptimalSize();
}
-extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeFontStyleBox(vcl::Window *pParent, VclBuilder::stringmap &rMap)
+VCL_BUILDER_DECL_FACTORY(FontStyleBox)
{
bool bDropdown = VclBuilder::extractDropdown(rMap);
WinBits nWinBits = WB_LEFT|WB_VCENTER|WB_3DLOOK|WB_TABSTOP;
@@ -1523,7 +1523,7 @@ FontSizeBox::FontSizeBox( vcl::Window* pParent, WinBits nWinSize ) :
ImplInit();
}
-extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeFontSizeBox(vcl::Window *pParent, VclBuilder::stringmap &rMap)
+VCL_BUILDER_DECL_FACTORY(FontSizeBox)
{
bool bDropdown = VclBuilder::extractDropdown(rMap);
WinBits nWinBits = WB_LEFT|WB_VCENTER|WB_3DLOOK|WB_TABSTOP;
diff --git a/svtools/source/control/fmtfield.cxx b/svtools/source/control/fmtfield.cxx
index a6202529274b..3ba6477517be 100644
--- a/svtools/source/control/fmtfield.cxx
+++ b/svtools/source/control/fmtfield.cxx
@@ -23,7 +23,7 @@
#include <comphelper/string.hxx>
#include <unotools/localedatawrapper.hxx>
#include <vcl/svapp.hxx>
-#include <vcl/builder.hxx>
+#include <vcl/builderfactory.hxx>
#include <vcl/settings.hxx>
#include <svl/zformat.hxx>
#include <svtools/fmtfield.hxx>
@@ -328,11 +328,7 @@ FormattedField::FormattedField(vcl::Window* pParent, WinBits nStyle, SvNumberFor
}
}
-extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeFormattedField(vcl::Window *pParent, VclBuilder::stringmap &)
-{
- WinBits nWinBits = WB_BORDER | WB_SPIN;
- return new FormattedField(pParent, nWinBits);
-}
+VCL_BUILDER_FACTORY_ARGS(FormattedField, WB_BORDER | WB_SPIN)
void FormattedField::SetText(const OUString& rStr)
{
diff --git a/svtools/source/control/inettbc.cxx b/svtools/source/control/inettbc.cxx
index 38dd2ba176f2..fe9a3ac034e8 100644
--- a/svtools/source/control/inettbc.cxx
+++ b/svtools/source/control/inettbc.cxx
@@ -43,7 +43,7 @@
#include <rtl/instance.hxx>
#include <salhelper/thread.hxx>
#include <osl/mutex.hxx>
-#include <vcl/builder.hxx>
+#include <vcl/builderfactory.hxx>
#include <vcl/svapp.hxx>
#include <vcl/toolbox.hxx>
#include <unotools/historyoptions.hxx>
@@ -863,8 +863,9 @@ SvtURLBox::SvtURLBox( vcl::Window* pParent, WinBits _nStyle, INetProtocol eSmart
Init(bSetDefaultHelpID);
}
-extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeSvtURLBox(vcl::Window *pParent, VclBuilder::stringmap &)
+VCL_BUILDER_DECL_FACTORY(SvtURLBox)
{
+ (void)rMap;
WinBits nWinBits = WB_LEFT|WB_VCENTER|WB_3DLOOK|WB_TABSTOP|
WB_DROPDOWN|WB_AUTOSIZE|WB_AUTOHSCROLL;
SvtURLBox* pListBox = new SvtURLBox(pParent, nWinBits, INetProtocol::NotValid, false);
diff --git a/svtools/source/control/urlcontrol.cxx b/svtools/source/control/urlcontrol.cxx
index 8f74b9c0e960..8a268d75e4c8 100644
--- a/svtools/source/control/urlcontrol.cxx
+++ b/svtools/source/control/urlcontrol.cxx
@@ -17,11 +17,10 @@
* the License at http://www.apache.org/licenses/LICENSE-2.0 .
*/
-
#include <svl/filenotation.hxx>
#include <svtools/urlcontrol.hxx>
#include <vcl/layout.hxx>
-
+#include <vcl/builderfactory.hxx>
namespace svt
{
@@ -32,8 +31,9 @@ namespace svt
DisableHistory();
}
- extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeOFileURLControl(vcl::Window *pParent, VclBuilder::stringmap &)
+ VCL_BUILDER_DECL_FACTORY(OFileURLControl)
{
+ (void)rMap;
WinBits nWinBits = WB_LEFT|WB_VCENTER|WB_3DLOOK|WB_TABSTOP|
WB_DROPDOWN|WB_AUTOSIZE|WB_AUTOHSCROLL;
OFileURLControl* pListBox = new OFileURLControl(pParent, nWinBits);
diff --git a/svtools/source/control/valueset.cxx b/svtools/source/control/valueset.cxx
index 617fde98209e..8d36028c636d 100644
--- a/svtools/source/control/valueset.cxx
+++ b/svtools/source/control/valueset.cxx
@@ -18,7 +18,7 @@
*/
#include <tools/debug.hxx>
-#include <vcl/builder.hxx>
+#include <vcl/builderfactory.hxx>
#include <vcl/decoview.hxx>
#include <vcl/svapp.hxx>
#include <vcl/scrbar.hxx>
@@ -103,7 +103,7 @@ ValueSet::ValueSet( vcl::Window* pParent, WinBits nWinStyle, bool bDisableTransi
mbIsTransientChildrenDisabled = bDisableTransientChildren;
}
-extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeValueSet(vcl::Window *pParent, VclBuilder::stringmap &rMap)
+VCL_BUILDER_DECL_FACTORY(ValueSet)
{
WinBits nWinBits = WB_TABSTOP;
diff --git a/svtools/source/edit/editsyntaxhighlighter.cxx b/svtools/source/edit/editsyntaxhighlighter.cxx
index 3d2c97701204..6e6965890d4e 100644
--- a/svtools/source/edit/editsyntaxhighlighter.cxx
+++ b/svtools/source/edit/editsyntaxhighlighter.cxx
@@ -20,7 +20,7 @@
#include <svtools/svmedit.hxx>
#include <vcl/xtextedt.hxx>
-#include <vcl/builder.hxx>
+#include <vcl/builderfactory.hxx>
#include <svtools/editsyntaxhighlighter.hxx>
#include <vcl/txtattr.hxx>
@@ -31,10 +31,7 @@ MultiLineEditSyntaxHighlight::MultiLineEditSyntaxHighlight( vcl::Window* pParent
EnableUpdateData(300);
}
-extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeMultiLineEditSyntaxHighlight(vcl::Window *pParent, VclBuilder::stringmap &)
-{
- return new MultiLineEditSyntaxHighlight(pParent);
-}
+VCL_BUILDER_FACTORY(MultiLineEditSyntaxHighlight)
void MultiLineEditSyntaxHighlight::SetText(const OUString& rNewText)
{