[Libreoffice-commits] core.git: Branch 'distro/collabora/co-2021' - sc/source

Pranam Lashkari (via logerrit) logerrit at kemper.freedesktop.org
Tue May 4 19:49:09 UTC 2021


 sc/source/ui/drawfunc/fuins1.cxx |    3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

New commits:
commit 2b57d51d3271722a5414971d78b3a6e48d0b1371
Author:     Pranam Lashkari <lpranam at collabora.com>
AuthorDate: Mon May 3 04:20:00 2021 +0530
Commit:     Pranam Lashkari <lpranam at collabora.com>
CommitDate: Tue May 4 21:48:36 2021 +0200

    LOK: calc: allow image selection on insertion
    
    in calc online, image was not selected by default when inserted
    
    problems:
    it was inconsistent with writer and impress/draw
    it caused problem in cypress testing
    
    Change-Id: Ic18b7a918c485a1cd384694d72fbb0a598d26ba2
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/114922
    Tested-by: Jenkins
    Reviewed-by: Pranam Lashkari <lpranam at collabora.com>
    (cherry picked from commit 931e264590100c555580c413556e229a0f03316a)
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115075
    Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice at gmail.com>

diff --git a/sc/source/ui/drawfunc/fuins1.cxx b/sc/source/ui/drawfunc/fuins1.cxx
index f314169f216e..31b597e9ea19 100644
--- a/sc/source/ui/drawfunc/fuins1.cxx
+++ b/sc/source/ui/drawfunc/fuins1.cxx
@@ -44,6 +44,7 @@
 #include <scresid.hxx>
 #include <strings.hrc>
 #include <globstr.hrc>
+#include <comphelper/lok.hxx>
 
 #include <com/sun/star/ui/dialogs/XFilePickerControlAccess.hpp>
 #include <com/sun/star/ui/dialogs/ExtendedFilePickerElementIds.hpp>
@@ -196,7 +197,7 @@ static void lcl_InsertGraphic( const Graphic& rGraphic,
                                                  aAnchorType == SCA_CELL_RESIZE);
 
     //  don't select if from (dispatch) API, to allow subsequent cell operations
-    SdrInsertFlags nInsOptions = bApi ? SdrInsertFlags::DONTMARK : SdrInsertFlags::NONE;
+    SdrInsertFlags nInsOptions = (bApi && !comphelper::LibreOfficeKit::isActive()) ? SdrInsertFlags::DONTMARK : SdrInsertFlags::NONE;
     bool bSuccess = pView->InsertObjectAtView( pObj, *pPV, nInsOptions );
 
     // SetGraphicLink has to be used after inserting the object,


More information about the Libreoffice-commits mailing list