vcl/source/control/ctrl.cxx |    5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

New commits:
commit 29d7b55af594e18065684ef127d781d76324c31b
Author:     Noel Grandin <noel.gran...@collabora.co.uk>
AuthorDate: Tue Jul 25 16:21:36 2023 +0200
Commit:     Noel Grandin <noel.gran...@collabora.co.uk>
CommitDate: Tue Jul 25 19:06:13 2023 +0200

    Control::LogicInvalidate takes a pixel rectangle
    
    not a logic rectangle
    
    Since
        commit 7adfecb0f5947ae258226c8d1652546f81577026
        Author: Marco Cecchetti <marco.cecche...@collabora.com>
        Date:   Sun Feb 5 17:47:34 2023 +0100
        lok: form controls: rendering and mouse event forwarding
    
    Change-Id: Ibbc0ea03d014ac2141bd59858f0a73e74ffe1144
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/154895
    Tested-by: Jenkins
    Tested-by: Marco Cecchetti <marco.cecche...@collabora.com>
    Reviewed-by: Marco Cecchetti <marco.cecche...@collabora.com>

diff --git a/vcl/source/control/ctrl.cxx b/vcl/source/control/ctrl.cxx
index 01454ef98c00..4f7a42badffc 100644
--- a/vcl/source/control/ctrl.cxx
+++ b/vcl/source/control/ctrl.cxx
@@ -500,14 +500,13 @@ void Control::LogicInvalidate(const tools::Rectangle* 
pRectangle)
     if (!pRectangle)
     {
         // we have to invalidate the whole control area not the whole document
-        aResultRectangle = tools::Rectangle(GetPosPixel(), GetSizePixel());
+        aResultRectangle = PixelToLogic(tools::Rectangle(GetPosPixel(), 
GetSizePixel()), MapMode(MapUnit::MapTwip));
     }
     else
     {
-        aResultRectangle = *pRectangle;
+        aResultRectangle = OutputDevice::LogicToLogic(*pRectangle, 
GetMapMode(), MapMode(MapUnit::MapTwip));
     }
 
-    aResultRectangle = PixelToLogic(aResultRectangle, 
MapMode(MapUnit::MapTwip));
     pParent->GetLOKNotifier()->notifyInvalidation(&aResultRectangle);
 }
 

Reply via email to