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 10:08:01 +0200
commiteb3193ffe0660a845210e4aba83aaefae3e003d7 (patch)
treefaff74c683bf16e412363b8f52868b3bcffd6c23
parent832ed2abb38d48d28b0b3deabfa6d8de799bdedb (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/79549 Reviewed-by: Tor Lillqvist <tml@collabora.com> Tested-by: Tor Lillqvist <tml@collabora.com> Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
-rw-r--r--sw/source/uibase/wrtsh/wrtsh1.cxx9
1 files changed, 8 insertions, 1 deletions
diff --git a/sw/source/uibase/wrtsh/wrtsh1.cxx b/sw/source/uibase/wrtsh/wrtsh1.cxx
index 183f964c9d25..a36efc29fbf7 100644
--- a/sw/source/uibase/wrtsh/wrtsh1.cxx
+++ b/sw/source/uibase/wrtsh/wrtsh1.cxx
@@ -579,7 +579,14 @@ void SwWrtShell::LaunchOLEObj( long nVerb )
{
svt::EmbeddedObjectRef& xRef = GetOLEObject();
OSL_ENSURE( xRef.is(), "OLE not found" );
- SfxInPlaceClient* pCli=nullptr;
+
+ // 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 = nullptr;
pCli = GetView().FindIPClient( xRef.GetObject(), &GetView().GetEditWin() );
if ( !pCli )