[Libreoffice-commits] core.git: sw/source

Marco Cecchetti (via logerrit) logerrit at kemper.freedesktop.org
Tue Dec 10 13:53:10 UTC 2019


 sw/source/uibase/uiview/view2.cxx |   23 +++++++++++++++++++++++
 1 file changed, 23 insertions(+)

New commits:
commit c715bb4197286ec474e7f9594bdb22935294bab8
Author:     Marco Cecchetti <marco.cecchetti at collabora.com>
AuthorDate: Sun Oct 6 22:06:28 2019 +0200
Commit:     Andras Timar <andras.timar at collabora.com>
CommitDate: Tue Dec 10 14:52:16 2019 +0100

    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 at collabora.com>

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;
 


More information about the Libreoffice-commits mailing list