sc/source/ui/view/tabview3.cxx |    3 +++
 1 file changed, 3 insertions(+)

New commits:
commit 30662ae380e3d31cc8904fcb1ceeb2592504834d
Author:     Justin Luth <jl...@mail.com>
AuthorDate: Thu Mar 9 15:23:19 2023 -0500
Commit:     Justin Luth <jl...@mail.com>
CommitDate: Sat Jun 10 18:52:50 2023 +0200

    tdf#347349 sc: avoid UpdateEditView when formula building
    
    The problem was that with a split window,
    the editview was being updated when switching to another sheet
    and then you couldn't select a cell during formula building.
    
    GetSelection from ActiveView was
    returning nothing if the editView was updated
    during the switch to another tab.
    
    This only happened under certain conditions
    that are detailed in the bug report.
    
    While I don't have much knowledge about the calc engine,
    this change seems reasonable enough to me to submit it.
    
    Change-Id: Ibb9a70fdfd57c2e1a1a7ae2ebafc4bf1b850f02a
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/148567
    Tested-by: Jenkins
    Reviewed-by: Justin Luth <jl...@mail.com>
    Reviewed-by: Dennis Francis <dennis.fran...@collabora.com>

diff --git a/sc/source/ui/view/tabview3.cxx b/sc/source/ui/view/tabview3.cxx
index 514341af267a..74f6fc3753b6 100644
--- a/sc/source/ui/view/tabview3.cxx
+++ b/sc/source/ui/view/tabview3.cxx
@@ -2169,6 +2169,9 @@ void ScTabView::MakeEditView( ScEditEngineDefaulter* 
pEngine, SCCOL nCol, SCROW
 
 void ScTabView::UpdateEditView()
 {
+    if (aViewData.GetTabNo() != aViewData.GetRefTabNo() && 
SC_MOD()->IsFormulaMode())
+        return;
+
     ScSplitPos eActive = aViewData.GetActivePart();
     for (sal_uInt16 i = 0; i < 4; i++)
     {

Reply via email to