[Libreoffice-commits] core.git: sd/source

Varun Dhall varun.dhall at studentpartner.com
Tue Aug 15 07:00:15 UTC 2017


 sd/source/core/stlpool.cxx |    5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

New commits:
commit 57db6e24b5ad43d447c30e44a112c74c7e75b46b
Author: Varun Dhall <varun.dhall at studentpartner.com>
Date:   Tue Aug 15 02:51:07 2017 +0530

    Removing old SfxItemSet::getHash usage
    
    Change-Id: I902da0f6e00253d5daf4bf65784dade2ae02740c
    Reviewed-on: https://gerrit.libreoffice.org/41155
    Reviewed-by: Michael Stahl <mstahl at redhat.com>
    Tested-by: Jenkins <ci at libreoffice.org>

diff --git a/sd/source/core/stlpool.cxx b/sd/source/core/stlpool.cxx
index 8065d00a9bf4..6397dc1f5fd6 100644
--- a/sd/source/core/stlpool.cxx
+++ b/sd/source/core/stlpool.cxx
@@ -651,9 +651,8 @@ void SdStyleSheetPool::CopySheets(SdStyleSheetPool& rSourcePool, SfxStyleFamily
             // if we have a rename suffix, try to find a new name
             pExistingSheet =
                 GetStyleSheetByPositionInIndex(aSheetsWithName.front()).get();
-            sal_Int32 nHash = xSheet->GetItemSet().getHash();
             if (!rRenameSuffix.isEmpty() &&
-                pExistingSheet->GetItemSet().getHash() != nHash)
+                pExistingSheet->GetItemSet().Equals(xSheet->GetItemSet(), false))
             {
                 // we have found a sheet with the same name, but different contents. Try to find a new name.
                 // If we already have a sheet with the new name, and it is equal to the one in the source pool,
@@ -665,7 +664,7 @@ void SdStyleSheetPool::CopySheets(SdStyleSheetPool& rSourcePool, SfxStyleFamily
                     aTmpName = aName + rRenameSuffix + OUString::number(nSuffix);
                     pExistingSheet = Find(aTmpName, eFamily);
                     nSuffix++;
-                } while( pExistingSheet && pExistingSheet->GetItemSet().getHash() != nHash );
+                } while( pExistingSheet && pExistingSheet->GetItemSet().Equals(xSheet->GetItemSet(), false) );
                 aName = aTmpName;
                 bAddToList = true;
             }


More information about the Libreoffice-commits mailing list