From 44f6329330e8c8f000cb310b04ac13777e8bfff3 Mon Sep 17 00:00:00 2001 From: Ashod Nakashian Date: Fri, 24 Jul 2020 11:33:46 -0400 Subject: sfx2: lok: refactor notifications and const correctness This reduces the stringification and reuses the notificaiton helpers to reduce code duplication. Change-Id: Icf9f9c50f3eeee61a0ded741d39fed37cfcc8da1 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/99972 Tested-by: Jenkins CollaboraOffice Reviewed-by: Ashod Nakashian Reviewed-on: https://gerrit.libreoffice.org/c/core/+/106221 Tested-by: Jenkins Reviewed-by: Tor Lillqvist --- desktop/source/lib/init.cxx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'desktop/source') diff --git a/desktop/source/lib/init.cxx b/desktop/source/lib/init.cxx index 8f82d577f3cc..6fe7347e9b70 100644 --- a/desktop/source/lib/init.cxx +++ b/desktop/source/lib/init.cxx @@ -2195,7 +2195,7 @@ static LibreOfficeKitDocument* lo_documentLoadWithOptions(LibreOfficeKit* pThis, LibLibreOffice_Impl* pLib = static_cast(pThis); pLib->maLastExceptionMsg.clear(); - OUString aURL(getAbsoluteURL(pURL)); + const OUString aURL(getAbsoluteURL(pURL)); if (aURL.isEmpty()) { pLib->maLastExceptionMsg = "Filename to load was not provided."; @@ -2291,7 +2291,7 @@ static LibreOfficeKitDocument* lo_documentLoadWithOptions(LibreOfficeKit* pThis, LibLODocument_Impl* pDocument = new LibLODocument_Impl(xComponent, nDocumentIdCounter++); - // Do we know that after loading the document, its initial view is the "current" view? + // After loading the document, its initial view is the "current" view. SfxLokHelper::setDocumentIdOfView(pDocument->mnDocumentId); if (pLib->mpCallback) { -- cgit v1.2.3