From aaffd4536c359c67da201e507264bf78636e66ad Mon Sep 17 00:00:00 2001 From: Pranav Kant Date: Fri, 3 Mar 2017 14:57:39 +0530 Subject: lok: Do not use UNO for fetching tracked changes See inline comment for reasons. Also, move the SwRedlineTypeToOUString function as inline to same header file containing redline types. Change-Id: I9b4be4f104c095b2ccd8287d935347c81fd25974 Reviewed-on: https://gerrit.libreoffice.org/34950 Tested-by: Jenkins Reviewed-by: pranavk (cherry picked from commit e6cca48bc9deb1049f8d501406269b71f91511ca) --- desktop/source/lib/init.cxx | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'desktop') diff --git a/desktop/source/lib/init.cxx b/desktop/source/lib/init.cxx index b462c1684f6b..3500d2b7673e 100644 --- a/desktop/source/lib/init.cxx +++ b/desktop/source/lib/init.cxx @@ -2500,7 +2500,10 @@ static char* getTrackedChanges(LibreOfficeKitDocument* pThis) uno::Reference xRedlinesSupplier(pDocument->mxComponent, uno::UNO_QUERY); std::stringstream aStream; - if (xRedlinesSupplier.is()) + // We want positions of the track changes also which is not possible from + // UNO. Enable positioning information for text documents only for now, so + // construct the tracked changes JSON from inside the sw/, not here using UNO + if (doc_getDocumentType(pThis) != LOK_DOCTYPE_TEXT && xRedlinesSupplier.is()) { uno::Reference xRedlines = xRedlinesSupplier->getRedlines()->createEnumeration(); boost::property_tree::ptree aRedlines; -- cgit