sc/source/core/data/patattr.cxx |    2 ++
 1 file changed, 2 insertions(+)

New commits:
commit 0f1228ea0e66f90d8cbe1c58d85a9d05a0e3a598
Author:     Caolán McNamara <caolan.mcnam...@collabora.com>
AuthorDate: Mon Nov 18 17:15:21 2024 +0000
Commit:     Xisco Fauli <xiscofa...@libreoffice.org>
CommitDate: Tue Nov 19 10:39:22 2024 +0100

    Resolves: tdf#163831 Invalidate cache if the style is modified
    
    Change-Id: I4a43936a6a7130734f5ae459a9406da99bf0f5f1
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/176728
    Reviewed-by: Xisco Fauli <xiscofa...@libreoffice.org>
    Tested-by: Jenkins

diff --git a/sc/source/core/data/patattr.cxx b/sc/source/core/data/patattr.cxx
index 162e46d5de4a..c41be794f2b0 100644
--- a/sc/source/core/data/patattr.cxx
+++ b/sc/source/core/data/patattr.cxx
@@ -210,6 +210,8 @@ void CellAttributeHelper::CellStyleCreated(ScDocument& 
rDoc, const OUString& rNa
         const ScPatternAttr* pCheck = *it;
         if (CompareStringPtr(pCheck->GetStyleName(), &rName) != 0)
             break;
+        // tdf#163831 Invalidate cache if the style is modified/created
+        const_cast<ScPatternAttr*>(pCheck)->InvalidateCaches();
         if (nullptr == pCheck->GetStyleSheet())
             if (const_cast<ScPatternAttr*>(pCheck)->UpdateStyleSheet(rDoc)) // 
find and store style pointer
             {

Reply via email to