[Libreoffice-commits] core.git: sc/qa sc/source

Gökay Şatır (via logerrit) logerrit at kemper.freedesktop.org
Tue Apr 13 12:49:38 UTC 2021


 sc/qa/unit/tiledrendering/tiledrendering.cxx |    4 ++--
 sc/source/ui/view/cliputil.cxx               |   16 +++++++++++++---
 2 files changed, 15 insertions(+), 5 deletions(-)

New commits:
commit b5b12537b784b3af9f2e2ad76536a55e281d6cfb
Author:     Gökay Şatır <gokay.satir at collabora.com>
AuthorDate: Mon Apr 12 14:36:46 2021 +0300
Commit:     Gökay ŞATIR <gokaysatir at collabora.com>
CommitDate: Tue Apr 13 14:48:58 2021 +0200

    Calc: Send sheet invalidation for full row/col ops
    
    Change-Id: I4da476804d2dfaf11c1cfd6cbe11cc4a651e0f09
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/113251
    Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice at gmail.com>
    Reviewed-by: Jan Holesovsky <kendy at collabora.com>
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/114038
    Tested-by: Jenkins
    Reviewed-by: Gökay ŞATIR <gokaysatir at collabora.com>

diff --git a/sc/qa/unit/tiledrendering/tiledrendering.cxx b/sc/qa/unit/tiledrendering/tiledrendering.cxx
index 1d883f0e4a95..9a9a5119c4a0 100644
--- a/sc/qa/unit/tiledrendering/tiledrendering.cxx
+++ b/sc/qa/unit/tiledrendering/tiledrendering.cxx
@@ -2336,8 +2336,8 @@ void ScTiledRenderingTest::testPasteIntoWrapTextCell()
     pView->GetViewFrame()->GetBindings().Execute(SID_PASTE);
     Scheduler::ProcessEventsToIdle();
 
-    // SG invalidations for rows
-    CPPUNIT_ASSERT_EQUAL(OString("rows"), aView.m_sInvalidateSheetGeometry);
+    // SG invalidations for all
+    CPPUNIT_ASSERT_EQUAL(OString("all"), aView.m_sInvalidateSheetGeometry);
 
     SfxViewShell::Current()->registerLibreOfficeKitViewCallback(nullptr, nullptr);
 }
diff --git a/sc/source/ui/view/cliputil.cxx b/sc/source/ui/view/cliputil.cxx
index d2db10b0a062..494c1b27c366 100644
--- a/sc/source/ui/view/cliputil.cxx
+++ b/sc/source/ui/view/cliputil.cxx
@@ -98,11 +98,21 @@ void ScClipUtil::PasteFromClipboard( ScViewData& rViewData, ScTabViewShell* pTab
     }
     if (comphelper::LibreOfficeKit::isActive())
     {
-        const ScLineBreakCell* pItem = rThisDoc.GetAttr(nThisCol, nThisRow, nThisTab, ATTR_LINEBREAK);
-        if (pItem && pItem->GetValue())
+        bool entireColumnOrRowSelected = false;
+        if (pOwnClip)
+        {
+            ScClipParam clipParam = pOwnClip->GetDocument()->GetClipParam();
+            if (clipParam.maRanges.size() > 0)
+            {
+                if (clipParam.maRanges[0].aEnd.Col() == MAXCOLCOUNT -1 || clipParam.maRanges[0].aEnd.Row() == MAXROWCOUNT - 1)
+                    entireColumnOrRowSelected = true;
+            }
+        }
+        const SfxBoolItem* pItem = rThisDoc.GetAttr(nThisCol, nThisRow, nThisTab, ATTR_LINEBREAK);
+        if (pItem->GetValue() || entireColumnOrRowSelected)
         {
             ScTabViewShell::notifyAllViewsSheetGeomInvalidation(
-                pTabViewShell, false /* bColumns */, true /* bRows */, true /* bSizes*/,
+                pTabViewShell, true /* bColumns */, true /* bRows */, true /* bSizes*/,
                 true /* bHidden */, true /* bFiltered */, true /* bGroups */, nThisTab);
         }
     }


More information about the Libreoffice-commits mailing list