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

Tamás Zolnai (via logerrit) logerrit at kemper.freedesktop.org
Tue Jul 16 16:04:22 UTC 2019


 sw/source/core/crsr/bookmrk.cxx |    9 ++++++++-
 1 file changed, 8 insertions(+), 1 deletion(-)

New commits:
commit 13a2db4941447001b81b077ee587903ae84cfc91
Author:     Tamás Zolnai <tamas.zolnai at collabora.com>
AuthorDate: Tue Jul 16 11:14:45 2019 +0100
Commit:     Tamás Zolnai <tamas.zolnai at collabora.com>
CommitDate: Tue Jul 16 18:03:29 2019 +0200

    tdf#126414: MSForms: fix flickering of date field button on Windows
    
    Need to ignore empty paint area parameters.
    
    Change-Id: I195d7bf9b3914199984f4a732d7616520d51dbba
    Reviewed-on: https://gerrit.libreoffice.org/75708
    Tested-by: Jenkins
    Reviewed-by: Tamás Zolnai <tamas.zolnai at collabora.com>

diff --git a/sw/source/core/crsr/bookmrk.cxx b/sw/source/core/crsr/bookmrk.cxx
index 769268d15b15..e1230a94a7bd 100644
--- a/sw/source/core/crsr/bookmrk.cxx
+++ b/sw/source/core/crsr/bookmrk.cxx
@@ -583,19 +583,26 @@ namespace sw { namespace mark
         {
             if(!m_pButton)
                 m_pButton = VclPtr<DateFormFieldButton>::Create(pEditWin, *this, m_pNumberFormatter);
-            m_pButton->CalcPosAndSize(m_aPaintAreaEnd);
+            SwRect aPaintArea(m_aPaintAreaStart.TopLeft(), m_aPaintAreaEnd.BottomRight());
+            m_pButton->CalcPosAndSize(aPaintArea);
             m_pButton->Show();
         }
     }
 
     void DateFieldmark::SetPortionPaintAreaStart(const SwRect& rPortionPaintArea)
     {
+        if (rPortionPaintArea.IsEmpty())
+            return;
+
         m_aPaintAreaStart = rPortionPaintArea;
         InvalidateCurrentDateParam();
     }
 
     void DateFieldmark::SetPortionPaintAreaEnd(const SwRect& rPortionPaintArea)
     {
+        if (rPortionPaintArea.IsEmpty())
+            return;
+
         if(m_aPaintAreaEnd == rPortionPaintArea &&
            m_pButton && m_pButton->IsVisible())
             return;


More information about the Libreoffice-commits mailing list