[Libreoffice-commits] core.git: cui/source
Caolán McNamara (via logerrit)
logerrit at kemper.freedesktop.org
Sun Dec 1 19:08:21 UTC 2019
cui/source/customize/CustomNotebookbarGenerator.cxx | 7 +++++--
1 file changed, 5 insertions(+), 2 deletions(-)
New commits:
commit b1f9e704cb9148b6e211005dab0cd153957a1b2b
Author: Caolán McNamara <caolanm at redhat.com>
AuthorDate: Sun Dec 1 14:41:19 2019 +0000
Commit: Caolán McNamara <caolanm at redhat.com>
CommitDate: Sun Dec 1 20:07:40 2019 +0100
Resolves: tdf#129119 no SfxViewFrame in startcenter
Change-Id: I16d8207314146df3dd7f5b11182650066cc97fde
Reviewed-on: https://gerrit.libreoffice.org/84148
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm at redhat.com>
Tested-by: Caolán McNamara <caolanm at redhat.com>
diff --git a/cui/source/customize/CustomNotebookbarGenerator.cxx b/cui/source/customize/CustomNotebookbarGenerator.cxx
index 8c135b96b8ff..374b1450ae97 100644
--- a/cui/source/customize/CustomNotebookbarGenerator.cxx
+++ b/cui/source/customize/CustomNotebookbarGenerator.cxx
@@ -215,10 +215,13 @@ void CustomNotebookbarGenerator::modifyCustomizedUIFile(const Sequence<OUString>
void CustomNotebookbarGenerator::getFileNameAndAppName(OUString& sAppName,
OUString& sNotebookbarUIFileName)
{
+ SfxViewFrame* pFrame = SfxViewFrame::Current();
+ if (!pFrame)
+ return;
+
const auto xContext = comphelper::getProcessComponentContext();
utl::OConfigurationTreeRoot aRoot(xContext, "org.openoffice.Office.UI.ToolbarMode/", false);
- const Reference<frame::XFrame>& xFrame
- = SfxViewFrame::Current()->GetFrame().GetFrameInterface();
+ const Reference<frame::XFrame>& xFrame = pFrame->GetFrame().GetFrameInterface();
const Reference<frame::XModuleManager> xModuleManager = frame::ModuleManager::create(xContext);
vcl::EnumContext::Application eApp
More information about the Libreoffice-commits
mailing list