[Libreoffice-commits] core.git: Branch 'libreoffice-5-3' - sc/source

Eike Rathke erack at redhat.com
Wed Jan 25 20:35:41 UTC 2017


 sc/source/core/data/conditio.cxx |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit f6587264b2c5b9191a4a7b547416c366db1c5607
Author: Eike Rathke <erack at redhat.com>
Date:   Wed Jan 25 11:40:52 2017 +0100

    Resolves: tdf#104675 ScConditionalFormat ranges needed to start listening
    
    Conditional format manager dialog holds a cloned list of
    ScConditionalFormat and sets that at the document on OK. The ranges of a
    format need to be set before ScFormatEntry/ScConditionEntry are added to
    start their listeners.
    
    Change-Id: I903553b1f6a8298838ee8753315a6ea263b29b08
    (cherry picked from commit 657eea01046c7f39ee8ca4545241372177385946)
    Reviewed-on: https://gerrit.libreoffice.org/33525
    Tested-by: Jenkins <ci at libreoffice.org>
    Reviewed-by: Caolán McNamara <caolanm at redhat.com>
    Tested-by: Caolán McNamara <caolanm at redhat.com>

diff --git a/sc/source/core/data/conditio.cxx b/sc/source/core/data/conditio.cxx
index 0f8764b..6657dcf 100644
--- a/sc/source/core/data/conditio.cxx
+++ b/sc/source/core/data/conditio.cxx
@@ -1776,6 +1776,7 @@ ScConditionalFormat* ScConditionalFormat::Clone(ScDocument* pNewDoc) const
         pNewDoc = pDoc;
 
     ScConditionalFormat* pNew = new ScConditionalFormat(nKey, pNewDoc);
+    pNew->SetRange( maRanges );     // prerequisite for listeners
 
     for (CondFormatContainer::const_iterator itr = maEntries.begin(); itr != maEntries.end(); ++itr)
     {
@@ -1783,7 +1784,6 @@ ScConditionalFormat* ScConditionalFormat::Clone(ScDocument* pNewDoc) const
         pNew->maEntries.push_back( std::unique_ptr<ScFormatEntry>(pNewEntry) );
         pNewEntry->SetParent(pNew);
     }
-    pNew->SetRange( maRanges );
 
     return pNew;
 }


More information about the Libreoffice-commits mailing list