summaryrefslogtreecommitdiff
path: root/desktop
diff options
context:
space:
mode:
authorMike Kaganski <mike.kaganski@collabora.com>2022-08-17 08:40:31 +0300
committerMike Kaganski <mike.kaganski@collabora.com>2022-08-17 11:59:38 +0200
commitb34577840b679b428490ae24fd644645ca5c76f0 (patch)
tree33526d766cbdef36f57f04bd11ca6591cd236025 /desktop
parent1433a0e3ebfe43d9f1aeb07d37facb4a529163df (diff)
Return std::optional instead of using bool* argument
Change-Id: I47f03411a6677f22291bea4dc06920ab9052349a Reviewed-on: https://gerrit.libreoffice.org/c/core/+/138399 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com> (cherry picked from commit 364e8272329ba893af4141ac054fdc71816bd44a) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/138291 Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Diffstat (limited to 'desktop')
-rw-r--r--desktop/source/lib/init.cxx7
1 files changed, 3 insertions, 4 deletions
diff --git a/desktop/source/lib/init.cxx b/desktop/source/lib/init.cxx
index 1533021c56a9..16bf1cb16542 100644
--- a/desktop/source/lib/init.cxx
+++ b/desktop/source/lib/init.cxx
@@ -2123,11 +2123,10 @@ void CallbackFlushHandler::enqueueUpdatedTypes()
void CallbackFlushHandler::enqueueUpdatedType( int type, const SfxViewShell* viewShell, int viewId )
{
- bool ignore = false;
- OString payload = viewShell->getLOKPayload( type, viewId, &ignore );
- if(ignore)
+ std::optional<OString> payload = viewShell->getLOKPayload( type, viewId );
+ if(!payload)
return; // No actual payload to send.
- CallbackData callbackData(payload.getStr(), viewId);
+ CallbackData callbackData(payload->getStr(), viewId);
m_queue1.emplace_back(type);
m_queue2.emplace_back(callbackData);
SAL_INFO("lok", "Queued updated [" << type << "]: [" << callbackData.getPayload()