summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMatúš Kukan <matus.kukan@collabora.com>2014-01-09 20:39:18 +0100
committerMatúš Kukan <matus.kukan@collabora.com>2014-01-10 16:29:23 +0100
commitd3e9334333080e75de95977c0594b35a1d3da5b4 (patch)
treebad52da27cf3c0f453cecf484cd6e1e8badd4443
parent98b2529e91255c68b6582dbe8aaaadbaf59cdd27 (diff)
fwk: Use constructor feature for LayoutManager.
Change-Id: I8f5167f7e522585ce8b80ebd8a9a0031aea50d74
-rw-r--r--framework/source/layoutmanager/layoutmanager.cxx12
-rw-r--r--framework/source/register/registerservices.cxx2
-rw-r--r--framework/util/fwk.component3
3 files changed, 14 insertions, 3 deletions
diff --git a/framework/source/layoutmanager/layoutmanager.cxx b/framework/source/layoutmanager/layoutmanager.cxx
index b49c10a790b3..dfe692b6f132 100644
--- a/framework/source/layoutmanager/layoutmanager.cxx
+++ b/framework/source/layoutmanager/layoutmanager.cxx
@@ -75,6 +75,7 @@
#include <rtl/instance.hxx>
#include <unotools/cmdoptions.hxx>
+#include <rtl/ref.hxx>
#include <rtl/strbuf.hxx>
#include <algorithm>
@@ -3224,4 +3225,15 @@ uno::Reference< beans::XPropertySetInfo > SAL_CALL LayoutManager::getPropertySet
} // namespace framework
+extern "C" SAL_DLLPUBLIC_EXPORT css::uno::XInterface * SAL_CALL
+com_sun_star_comp_framework_LayoutManager_get_implementation(
+ css::uno::XComponentContext * context,
+ uno_Sequence * arguments)
+{
+ assert(arguments != 0 && arguments->nElements == 0); (void) arguments;
+ rtl::Reference<framework::LayoutManager> x(new framework::LayoutManager(context));
+ x->acquire();
+ return static_cast<cppu::OWeakObject *>(x.get());
+}
+
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/framework/source/register/registerservices.cxx b/framework/source/register/registerservices.cxx
index 4e4a66306582..6bf2e474f08a 100644
--- a/framework/source/register/registerservices.cxx
+++ b/framework/source/register/registerservices.cxx
@@ -36,7 +36,6 @@
#include <services/desktop.hxx>
#include <services/frame.hxx>
#include <jobs/jobexecutor.hxx>
-#include <services/layoutmanager.hxx>
#include <uielement/controlmenucontroller.hxx>
#include <accelerators/globalacceleratorconfiguration.hxx>
#include <accelerators/documentacceleratorconfiguration.hxx>
@@ -50,7 +49,6 @@ COMPONENTGETFACTORY ( fwk,
IFFACTORY( ::framework::Desktop ) else
IFFACTORY( ::framework::Frame ) else
IFFACTORY( ::framework::JobExecutor ) else
- IFFACTORY( ::framework::LayoutManager ) else
IFFACTORY( ::framework::ControlMenuController ) else
IFFACTORY( ::framework::GlobalAcceleratorConfiguration ) else
IFFACTORY( ::framework::DocumentAcceleratorConfiguration ) else
diff --git a/framework/util/fwk.component b/framework/util/fwk.component
index 5b860799c039..f5321657b80f 100644
--- a/framework/util/fwk.component
+++ b/framework/util/fwk.component
@@ -58,7 +58,8 @@
constructor="com_sun_star_comp_framework_LangSelectionStatusbarController_get_implementation">
<service name="com.sun.star.frame.StatusbarController"/>
</implementation>
- <implementation name="com.sun.star.comp.framework.LayoutManager">
+ <implementation name="com.sun.star.comp.framework.LayoutManager"
+ constructor="com_sun_star_comp_framework_LayoutManager_get_implementation">
<service name="com.sun.star.frame.LayoutManager"/>
</implementation>
<implementation name="com.sun.star.comp.framework.MenuBarFactory"