summaryrefslogtreecommitdiff
path: root/framework/source/services
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2015-08-19 15:27:07 +0100
committerCaolán McNamara <caolanm@redhat.com>2015-08-19 20:28:35 +0100
commitf0e90c712b701b2d3b4f4725dfbed8c5ea924b0f (patch)
treef6de2296f69e8ea7ef9f2d51b79bd254b8dc042a /framework/source/services
parentb27417623835b1c82475783979a1fb9656b5155e (diff)
for testing allow disabling configmgr for time critical paths
Change-Id: I83396e7c90d3b182f353a77c9bdf06fd17af92a1
Diffstat (limited to 'framework/source/services')
-rw-r--r--framework/source/services/desktop.cxx7
1 files changed, 5 insertions, 2 deletions
diff --git a/framework/source/services/desktop.cxx b/framework/source/services/desktop.cxx
index 32add3feb417..9c2eb1c02e79 100644
--- a/framework/source/services/desktop.cxx
+++ b/framework/source/services/desktop.cxx
@@ -63,6 +63,7 @@
#include <vcl/svapp.hxx>
#include <tools/errinf.hxx>
+#include <unotools/configmgr.hxx>
#include <comphelper/extract.hxx>
namespace framework{
@@ -162,7 +163,6 @@ Desktop::Desktop( const css::uno::Reference< css::uno::XComponentContext >& xCon
, m_xLastFrame ( )
, m_aInteractionRequest ( )
, m_bSuspendQuickstartVeto( false )
- , m_aCommandOptions ( )
, m_sName ( )
, m_sTitle ( )
, m_xDispatchRecorderSupplier( )
@@ -646,8 +646,11 @@ css::uno::Reference< css::frame::XDispatch > SAL_CALL Desktop::queryDispatch( co
if ( aURL.Protocol.equalsIgnoreAsciiCase(".uno:") )
aCommand = aURL.Path;
+ if (!m_xCommandOptions && !utl::ConfigManager::IsAvoidConfig())
+ m_xCommandOptions.reset(new SvtCommandOptions);
+
// Make std::unordered_map lookup if the current URL is in the disabled list
- if ( m_aCommandOptions.Lookup( SvtCommandOptions::CMDOPTION_DISABLED, aCommand ) )
+ if (m_xCommandOptions && m_xCommandOptions->Lookup(SvtCommandOptions::CMDOPTION_DISABLED, aCommand))
return css::uno::Reference< css::frame::XDispatch >();
else
{