Kaydet (Commit) 897d7314 authored tarafından Markus Mohrhard's avatar Markus Mohrhard

reduce the amount of senseless exceptions during document load

Change-Id: If9d0a0539002c013f077b8fb692de4c29ca032b7
Reviewed-on: https://gerrit.libreoffice.org/64791
Tested-by: Jenkins
Reviewed-by: 's avatarMarkus Mohrhard <markus.mohrhard@googlemail.com>
üst 3f5dbc06
......@@ -1453,7 +1453,7 @@ void MenuBarManager::FillMenu(
aProp[i].Value >>= bEnabled;
}
if (vcl::CommandInfoProvider::IsExperimental(aCommandURL, rModuleIdentifier) &&
if (!aCommandURL.isEmpty() && vcl::CommandInfoProvider::IsExperimental(aCommandURL, rModuleIdentifier) &&
!SvtMiscOptions().IsExperimentalMode())
{
continue;
......
......@@ -1009,7 +1009,7 @@ void ToolBarManager::FillToolbar( const Reference< XIndexAccess >& rItemContaine
aProp[i].Value >>= nStyle;
}
if (vcl::CommandInfoProvider::IsExperimental(aCommandURL, m_aModuleIdentifier) &&
if (!aCommandURL.isEmpty() && vcl::CommandInfoProvider::IsExperimental(aCommandURL, m_aModuleIdentifier) &&
!SvtMiscOptions().IsExperimentalMode())
{
continue;
......
......@@ -194,7 +194,7 @@ static Sequence<beans::PropertyValue> GetCommandProperties(const OUString& rsCom
{
Reference<container::XNameAccess> xNameAccess(GetCommandDescription());
Reference<container::XNameAccess> xUICommandLabels;
if (xNameAccess->getByName(rsModuleName) >>= xUICommandLabels)
if ((xNameAccess->getByName(rsModuleName) >>= xUICommandLabels) && xUICommandLabels->hasByName(rsCommandName))
xUICommandLabels->getByName(rsCommandName) >>= aProperties;
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment