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

Noel Grandin (via logerrit) logerrit at kemper.freedesktop.org
Sat Jul 10 07:41:39 UTC 2021


 sw/source/core/txtnode/thints.cxx |   10 +++-------
 1 file changed, 3 insertions(+), 7 deletions(-)

New commits:
commit 4a93efcf6e7982146fb71e4d32760a07a0f984c2
Author:     Noel Grandin <noelgrandin at gmail.com>
AuthorDate: Thu Jul 8 15:16:29 2021 +0200
Commit:     Noel Grandin <noel.grandin at collabora.co.uk>
CommitDate: Sat Jul 10 09:41:03 2021 +0200

    try to restore SwpHints::MergePortions...
    
    ... logic to how it was trying to work before I started messing with it in
        commit 568b820bc2d52c007ee08ad7a3849c94a458115d
        Author: Noel Grandin <noel.grandin at collabora.co.uk>
        Date:   Tue Dec 17 15:11:34 2019 +0200
    
        tdf#119227 fix freeze when copying a large bulleted list
    
        freeze goes from 5 seconds to about 1 second for me
    
        (1) used unordered_map instead of map
        (2) don't create temporary SfxItemSet's just to check equality
    
    and then I tried to fix that in
        commit 18e4367c33f327cf09985105bde583cdcc7b2a46
        Author: Noel Grandin <noel.grandin at collabora.co.uk>
        Date:   Thu Sep 3 14:40:32 2020 +0200
    
        tdf#132688 diacritics broken in lines with punctuation
    
        regression from
            commit 4b2d4f3c4a68361a6bc03c9ab110ce9376b14b20
            tdf#119227 fix freeze when copying a large bulleted list
    
    and then Andreas tried some more in
        commit 003d65ef1305eefb43315f93bdf10cee787f90f0
        Author: Andreas Heinisch <andreas.heinisch at yahoo.de>
        Date:   Mon Jul 5 22:32:52 2021 +0200
    
        tdf#140197 - Letter cut off at certain zoom-level
    
        regression from
                commit 4b2d4f3c4a68361a6bc03c9ab110ce9376b14b20
                tdf#119227 fix freeze when copying a large bulleted list
    
    Change-Id: Id9d04f96ccbe496ed809cf08e7aab25d6464913f
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/118643
    Tested-by: Jenkins
    Reviewed-by: Noel Grandin <noel.grandin at collabora.co.uk>

diff --git a/sw/source/core/txtnode/thints.cxx b/sw/source/core/txtnode/thints.cxx
index ebc751dc39e3..03fd7be3affc 100644
--- a/sw/source/core/txtnode/thints.cxx
+++ b/sw/source/core/txtnode/thints.cxx
@@ -2868,7 +2868,10 @@ static MergeResult lcl_Compare_Attributes(
                 if (pItem2->Which() == RES_CHRATR_RSID)
                     pItem2 = iter2.NextItem();
                 if (!pItem1 && !pItem2)
+                {
+                    eMerge = DIFFER_ONLY_RSID;
                     break;
+                }
                 if (!pItem1 || !pItem2)
                 {
                     return DIFFER;
@@ -2878,13 +2881,6 @@ static MergeResult lcl_Compare_Attributes(
                     assert(IsInvalidItem(pItem1) || IsInvalidItem(pItem2) || pItem1->Which() != pItem2->Which() || *pItem1 != *pItem2);
                     return DIFFER;
                 }
-                if (iter1.IsAtEnd() && iter2.IsAtEnd())
-                    break;
-                if (iter1.IsAtEnd() || iter2.IsAtEnd())
-                {
-                    eMerge = DIFFER_ONLY_RSID;
-                    break;
-                }
             }
             eMerge = DIFFER_ONLY_RSID;
         }


More information about the Libreoffice-commits mailing list