summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarco Cecchetti <marco.cecchetti@collabora.com>2019-10-06 22:06:28 +0200
committerAndras Timar <andras.timar@collabora.com>2019-12-10 14:52:16 +0100
commitc715bb4197286ec474e7f9594bdb22935294bab8 (patch)
treed8bf5c8def5aad23184e8103d591b5651c350690
parentc00eda32d18eab7fd88606b1c30bfcf05b7ee0a4 (diff)
lok: change-annotation navigation through prev/next command
Change-Id: Id62a84e0db24b4d317a5503d468f2e0caf13424b Reviewed-on: https://gerrit.libreoffice.org/82008 Tested-by: Jenkins Reviewed-by: Andras Timar <andras.timar@collabora.com>
-rw-r--r--sw/source/uibase/uiview/view2.cxx23
1 files changed, 23 insertions, 0 deletions
diff --git a/sw/source/uibase/uiview/view2.cxx b/sw/source/uibase/uiview/view2.cxx
index 43694ab1239b..3542ef25a560 100644
--- a/sw/source/uibase/uiview/view2.cxx
+++ b/sw/source/uibase/uiview/view2.cxx
@@ -130,6 +130,8 @@
#include <ndtxt.hxx>
#include <comphelper/processfactory.hxx>
+#include <comphelper/lok.hxx>
+#include <LibreOfficeKit/LibreOfficeKitEnums.h>
#include <svx/svxdlg.hxx>
#include <svx/dialogs.hrc>
@@ -785,7 +787,18 @@ void SwView::Execute(SfxRequest &rReq)
pNext = m_pWrtShell->SelNextRedline();
if (pNext)
+ {
+ if (comphelper::LibreOfficeKit::isActive())
+ {
+ OString aPayload(".uno:CurrentTrackedChangeId=");
+ sal_uInt32 nRedlineId = pNext->GetId();
+ aPayload += OString::number(nRedlineId);
+ libreOfficeKitViewCallback(LOK_CALLBACK_STATE_CHANGED, aPayload.getStr());
+ }
+
m_pWrtShell->SetInSelect();
+ }
+
}
break;
@@ -794,7 +807,17 @@ void SwView::Execute(SfxRequest &rReq)
const SwRangeRedline *pPrev = m_pWrtShell->SelPrevRedline();
if (pPrev)
+ {
+ if (comphelper::LibreOfficeKit::isActive())
+ {
+ OString aPayload(".uno:CurrentTrackedChangeId=");
+ sal_uInt32 nRedlineId = pPrev->GetId();
+ aPayload += OString::number(nRedlineId);
+ libreOfficeKitViewCallback(LOK_CALLBACK_STATE_CHANGED, aPayload.getStr());
+ }
+
m_pWrtShell->SetInSelect();
+ }
}
break;