summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPranam Lashkari <lpranam@collabora.com>2020-08-28 00:46:06 +0530
committerAndras Timar <andras.timar@collabora.com>2020-08-28 12:03:19 +0200
commit61621999e166bf96e1cd5c1c62012b821d312810 (patch)
tree58b35f285d5b7b1e96dbf6e66306f7fdb119ff0e
parentaae1c366ad6ff8bbf60a84cafecfce7172db077c (diff)
LOK: do not show calc notes in the online
Change-Id: I3d69aab2a76948182483025536dbc4ddc928a86e Reviewed-on: https://gerrit.libreoffice.org/c/core/+/101510 Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com> Reviewed-by: Andras Timar <andras.timar@collabora.com>
-rw-r--r--sc/source/filter/xml/xmlcelli.cxx16
1 files changed, 14 insertions, 2 deletions
diff --git a/sc/source/filter/xml/xmlcelli.cxx b/sc/source/filter/xml/xmlcelli.cxx
index 87627bbc84c7..57be73858ef9 100644
--- a/sc/source/filter/xml/xmlcelli.cxx
+++ b/sc/source/filter/xml/xmlcelli.cxx
@@ -109,6 +109,8 @@
#include <i18nlangtag/lang.h>
#include <o3tl/make_unique.hxx>
+#include <comphelper/lok.hxx>
+
using namespace com::sun::star;
using namespace xmloff::token;
@@ -881,7 +883,7 @@ void ScXMLTableRowCellContext::SetAnnotation(const ScAddress& rPos)
/* Try to reuse the drawing object already created (but only if the
note is visible, and the object is a caption object). */
- if( mxAnnotationData->mbShown && mxAnnotationData->mbUseShapePos )
+ if( mxAnnotationData->mbShown && mxAnnotationData->mbUseShapePos && !comphelper::LibreOfficeKit::isActive())
{
if( SdrCaptionObj* pCaption = dynamic_cast< SdrCaptionObj* >( pObject ) )
{
@@ -915,9 +917,19 @@ void ScXMLTableRowCellContext::SetAnnotation(const ScAddress& rPos)
if (xOutlinerObj)
{
// create cell note with all data from drawing object
- pNote = ScNoteUtil::CreateNoteFromObjectData( *pDoc, rPos,
+ if(!comphelper::LibreOfficeKit::isActive())
+ {
+ pNote = ScNoteUtil::CreateNoteFromObjectData( *pDoc, rPos,
std::move(xItemSet), xOutlinerObj.release(),
aCaptionRect, mxAnnotationData->mbShown );
+ }
+ else
+ {
+ pNote = ScNoteUtil::CreateNoteFromObjectData( *pDoc, rPos,
+ std::move(xItemSet), xOutlinerObj.release(),
+ aCaptionRect, false );
+ }
+
}
}
}