summaryrefslogtreecommitdiff
path: root/framework/source/uielement/uicommanddescription.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'framework/source/uielement/uicommanddescription.cxx')
-rw-r--r--framework/source/uielement/uicommanddescription.cxx23
1 files changed, 1 insertions, 22 deletions
diff --git a/framework/source/uielement/uicommanddescription.cxx b/framework/source/uielement/uicommanddescription.cxx
index d791ddfd89ab..4d9fccf5af41 100644
--- a/framework/source/uielement/uicommanddescription.cxx
+++ b/framework/source/uielement/uicommanddescription.cxx
@@ -710,33 +710,12 @@ sal_Bool SAL_CALL UICommandDescription::hasElements()
} // namespace framework
-namespace {
-
-struct Instance {
- explicit Instance(
- css::uno::Reference<css::uno::XComponentContext> const & context):
- instance(static_cast<cppu::OWeakObject *>(
- new framework::UICommandDescription(context)))
- {
- }
-
- css::uno::Reference<css::uno::XInterface> instance;
-};
-
-struct Singleton:
- public rtl::StaticWithArg<
- Instance, css::uno::Reference<css::uno::XComponentContext>, Singleton>
-{};
-
-}
-
extern "C" SAL_DLLPUBLIC_EXPORT css::uno::XInterface *
com_sun_star_comp_framework_UICommandDescription_get_implementation(
css::uno::XComponentContext *context,
css::uno::Sequence<css::uno::Any> const &)
{
- return cppu::acquire(static_cast<cppu::OWeakObject *>(
- Singleton::get(context).instance.get()));
+ return cppu::acquire(new framework::UICommandDescription(context));
}
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */