sw sd lok: Don't enter the OLE editing mode right after inserting a chart.
Turns out that it is confusing for the users that they can edit the properties of the chart rather than its position just after inserting it in the browser. Let's change it accordingly. When the user wants to edit the chart itself, they have to double-click. Calc is not handled in this patch. Change-Id: If5661b843a06ebaeb8d4cd1b2c469aeedda4257e Reviewed-on: https://gerrit.libreoffice.org/78318 Reviewed-by: Miklos Vajna <vmiklos@collabora.com> Tested-by: Jenkins
This commit is contained in:
committed by
Miklos Vajna
parent
c598ea1427
commit
758a4998c5
@@ -76,6 +76,8 @@
|
||||
#include <vcl/GraphicNativeTransform.hxx>
|
||||
#include <vcl/GraphicNativeMetadata.hxx>
|
||||
|
||||
#include <comphelper/lok.hxx>
|
||||
|
||||
using namespace com::sun::star;
|
||||
|
||||
namespace sd {
|
||||
@@ -390,8 +392,10 @@ void FuInsertOLE::DoExecute( SfxRequest& rReq )
|
||||
else
|
||||
bRet = mpView->InsertObjectAtView(pOleObj, *pPV, SdrInsertFlags::SETDEFLAYER);
|
||||
|
||||
if( bRet )
|
||||
if (bRet && !comphelper::LibreOfficeKit::isActive())
|
||||
{
|
||||
// Let the chart be activated after the inserting (unless
|
||||
// via LibreOfficeKit)
|
||||
if (nSlotId == SID_INSERT_DIAGRAM)
|
||||
{
|
||||
pOleObj->SetProgName( "StarChart");
|
||||
|
||||
@@ -48,6 +48,8 @@
|
||||
#include <unochart.hxx>
|
||||
#include <memory>
|
||||
|
||||
#include <comphelper/lok.hxx>
|
||||
|
||||
using namespace ::com::sun::star;
|
||||
|
||||
// Adjust line height (dialogue)
|
||||
@@ -248,9 +250,10 @@ uno::Reference< frame::XModel > SwTableFUNC::InsertChart(
|
||||
}
|
||||
pSh->EndAllAction();
|
||||
|
||||
if ( xObj.is() )
|
||||
if (xObj.is() && !comphelper::LibreOfficeKit::isActive())
|
||||
{
|
||||
// Let the chart be activated after the inserting
|
||||
// Let the chart be activated after the inserting (unless
|
||||
// via LibreOfficeKit)
|
||||
SfxInPlaceClient* pClient = pSh->GetView().FindIPClient( xObj, &pSh->GetView().GetEditWin() );
|
||||
if ( !pClient )
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user