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

Noel Grandin (via logerrit) logerrit at kemper.freedesktop.org
Wed Apr 24 14:11:47 UTC 2019


 svx/source/unodraw/unoshtxt.cxx |    8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

New commits:
commit 88be8aa14d52ad102dc6b01c1c962d4e6cac4941
Author:     Noel Grandin <noel.grandin at collabora.co.uk>
AuthorDate: Wed Apr 24 13:36:18 2019 +0200
Commit:     Noel Grandin <noel.grandin at collabora.co.uk>
CommitDate: Wed Apr 24 16:10:36 2019 +0200

    tdf#89522 PERF FILEOPEN xlsx, part 2
    
    re-arrange the conditions so we avoid the dynamic_cast most of the time.
    
    This takes the file-open time from 40s to 29s for me.
    
    Change-Id: If65a63502fd545003137747605332be65d5e91ca
    Reviewed-on: https://gerrit.libreoffice.org/71229
    Reviewed-by: Noel Grandin <noel.grandin at collabora.co.uk>
    Tested-by: Noel Grandin <noel.grandin at collabora.co.uk>

diff --git a/svx/source/unodraw/unoshtxt.cxx b/svx/source/unodraw/unoshtxt.cxx
index dbfb5a544c6c..9ea667c396f9 100644
--- a/svx/source/unodraw/unoshtxt.cxx
+++ b/svx/source/unodraw/unoshtxt.cxx
@@ -265,10 +265,6 @@ void SvxTextEditSourceImpl::Notify(SfxBroadcaster& rBC, const SfxHint& rHint)
             mpViewForwarder.reset();
         }
     }
-    else if (const SvxViewChangedHint* pViewHint = dynamic_cast<const SvxViewChangedHint*>(&rHint))
-    {
-        Broadcast( *pViewHint );
-    }
     else if (rHint.GetId() == SfxHintId::ThisIsAnSdrHint)
     {
         const SdrHint* pSdrHint = static_cast<const SdrHint*>(&rHint);
@@ -377,6 +373,10 @@ void SvxTextEditSourceImpl::Notify(SfxBroadcaster& rBC, const SfxHint& rHint)
                 break;
         }
     }
+    else if (const SvxViewChangedHint* pViewHint = dynamic_cast<const SvxViewChangedHint*>(&rHint))
+    {
+        Broadcast( *pViewHint );
+    }
 }
 
 /* this is a callback from the attached SdrObject when it is actually deleted */


More information about the Libreoffice-commits mailing list