summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJan Holesovsky <kendy@collabora.com>2019-09-25 11:40:46 +0200
committerJan Holesovsky <kendy@collabora.com>2019-09-26 09:33:05 +0200
commitb3f249c1351642be6f2774230ff80a6d20bd1401 (patch)
treeffb6747b2f0e82ec076d054b035a2696d6a182b5
parentdfaf6ebc1ebadd1ea4bb334b1adf4172e3aa205c (diff)
tdf#127673 lok: On double-click, don't enter the embedded objects in Writer.
There are all sorts of problems when we'd try to edit the embedded objects, like that that LOK thinks it is a separate view etc., so better to disable it for now, before we really need to edit embedded objects. Change-Id: Ie8c0249cb0ca8b25a2ac97c1ccec4a5a62cbb770 Reviewed-on: https://gerrit.libreoffice.org/79555 Tested-by: Jenkins Reviewed-by: Jan Holesovsky <kendy@collabora.com>
-rw-r--r--sw/source/uibase/wrtsh/wrtsh1.cxx6
1 files changed, 6 insertions, 0 deletions
diff --git a/sw/source/uibase/wrtsh/wrtsh1.cxx b/sw/source/uibase/wrtsh/wrtsh1.cxx
index 52f30e803973..013da2115b51 100644
--- a/sw/source/uibase/wrtsh/wrtsh1.cxx
+++ b/sw/source/uibase/wrtsh/wrtsh1.cxx
@@ -626,6 +626,12 @@ void SwWrtShell::LaunchOLEObj( long nVerb )
svt::EmbeddedObjectRef& xRef = GetOLEObject();
OSL_ENSURE( xRef.is(), "OLE not found" );
+ // LOK: we don't want to handle any other embedded objects than
+ // charts, there are too many problems with eg. embedded spreadsheets
+ // (like it creates a separate view for the calc sheet)
+ if (comphelper::LibreOfficeKit::isActive() && !SotExchange::IsChart(xRef->getClassID()))
+ return;
+
SfxInPlaceClient* pCli = GetView().FindIPClient( xRef.GetObject(), &GetView().GetEditWin() );
if ( !pCli )
pCli = new SwOleClient( &GetView(), &GetView().GetEditWin(), xRef );