[Libreoffice-commits] core.git: vcl/osx

Noel Grandin (via logerrit) logerrit at kemper.freedesktop.org
Sun Mar 7 17:49:42 UTC 2021


 vcl/osx/salnativewidgets.cxx |   12 ++++--------
 1 file changed, 4 insertions(+), 8 deletions(-)

New commits:
commit 901fee94302e1b6366a5df2859f1f13ff0c4afca
Author:     Noel Grandin <noelgrandin at gmail.com>
AuthorDate: Sun Mar 7 17:58:53 2021 +0200
Commit:     Noel Grandin <noel.grandin at collabora.co.uk>
CommitDate: Sun Mar 7 18:48:57 2021 +0100

    tdf#140856 macOS listbox rendering
    
    Change-Id: Ib5d4af162da7264d9e6da8742e36c194448bd1fd
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/112132
    Tested-by: Jenkins
    Reviewed-by: Thorsten Wagner <thorsten.wagner.4 at gmail.com>
    Reviewed-by: Noel Grandin <noel.grandin at collabora.co.uk>

diff --git a/vcl/osx/salnativewidgets.cxx b/vcl/osx/salnativewidgets.cxx
index 5dd5929c2fc6..bc132ee88d16 100644
--- a/vcl/osx/salnativewidgets.cxx
+++ b/vcl/osx/salnativewidgets.cxx
@@ -735,10 +735,6 @@ bool AquaSalGraphics::drawNativeControl(ControlType nType,
                     aTextDrawInfo.kind = kHIThemeFrameListBox;
                     aTextDrawInfo.state = kThemeStateActive;
                     aTextDrawInfo.isFocused = false;
-                    rc.size.width += 2 * kThemeMetricListBoxFrameOutset - 2;
-                    rc.size.height += 2 * kThemeMetricListBoxFrameOutset - 2;
-                    rc.origin.x -= kThemeMetricListBoxFrameOutset - 1;
-                    rc.origin.y -= kThemeMetricListBoxFrameOutset - 1;
                     HIThemeDrawFrame(&rc, &aTextDrawInfo, maContextHolder.get(), kHIThemeOrientationNormal);
                     bOK = true;
                     break;
@@ -1046,10 +1042,10 @@ bool AquaSalGraphics::getNativeControlRegion(ControlType nType,
             }
             else if (nPart == ControlPart::ListboxWindow)
             {
-                w = aCtrlBoundRect.GetWidth() - 2 * kThemeMetricListBoxFrameOutset;
-                h = aCtrlBoundRect.GetHeight() - 2 * kThemeMetricListBoxFrameOutset;
-                x += kThemeMetricListBoxFrameOutset;
-                y += kThemeMetricListBoxFrameOutset;
+                w = aCtrlBoundRect.GetWidth() - 2;
+                h = aCtrlBoundRect.GetHeight() - 2;
+                x += 1;
+                y += 1;
                 rNativeBoundingRegion = aCtrlBoundRect;
                 rNativeContentRegion = tools::Rectangle(Point(x, y), Size(w, h));
                 toReturn = true;


More information about the Libreoffice-commits mailing list