[Libreoffice-commits] core.git: libreofficekit/qa

Pranav Kant pranavk at collabora.co.uk
Mon Feb 20 08:39:01 UTC 2017


 libreofficekit/qa/gtktiledviewer/gtktiledviewer.cxx |    7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)

New commits:
commit 57d75ba3176063249e27524a7c7e425b3a2e75b4
Author: Pranav Kant <pranavk at collabora.co.uk>
Date:   Mon Feb 20 11:27:53 2017 +0530

    gtktiledviewer: Different reply uno command for impress
    
    Change-Id: I9dcd32a7e64198ca4772f263ed89a458e298c53b

diff --git a/libreofficekit/qa/gtktiledviewer/gtktiledviewer.cxx b/libreofficekit/qa/gtktiledviewer/gtktiledviewer.cxx
index c8bf3ee..59faff1 100644
--- a/libreofficekit/qa/gtktiledviewer/gtktiledviewer.cxx
+++ b/libreofficekit/qa/gtktiledviewer/gtktiledviewer.cxx
@@ -330,7 +330,12 @@ static void replyButtonClicked(GtkWidget* pWidget, gpointer userdata)
     boost::property_tree::write_json(aStream, aTree);
     std::string aArguments = aStream.str();
 
-    lok_doc_view_post_command(LOK_DOC_VIEW(rWindow.m_pDocView), ".uno:ReplyComment", aArguments.c_str(), false);
+    // Different reply UNO command for impress
+    std::string replyCommand = ".uno:ReplyComment";
+    LibreOfficeKitDocument* pDocument = lok_doc_view_get_document(LOK_DOC_VIEW(rWindow.m_pDocView));
+    if (pDocument && pDocument->pClass->getDocumentType(pDocument) == LOK_DOCTYPE_PRESENTATION)
+        replyCommand = ".uno:ReplyToAnnotation";
+    lok_doc_view_post_command(LOK_DOC_VIEW(rWindow.m_pDocView), replyCommand.c_str(), aArguments.c_str(), false);
 }
 
 static void deleteCommentButtonClicked(GtkWidget* pWidget, gpointer userdata)


More information about the Libreoffice-commits mailing list