From c5a3022b041f19c3bc2dd2204c9f9b334c7f986f Mon Sep 17 00:00:00 2001 From: Gabriel de Dietrich Date: Wed, 20 Dec 2017 17:14:18 -0800 Subject: [PATCH] QMacStyle: Minimize size of scrollbar transparency layer Instead of allocating the full backing store size for the transparency layer, we make sure we only allocate exactly as much as needed by the scrollbar. Change-Id: I55c3172fe3dd2a1f3fd46828463497f9f35cb1ae Reviewed-by: Jake Petroules --- src/plugins/styles/mac/qmacstyle_mac.mm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/plugins/styles/mac/qmacstyle_mac.mm b/src/plugins/styles/mac/qmacstyle_mac.mm index ad2ca4a02ee..db02ab1fe9b 100644 --- a/src/plugins/styles/mac/qmacstyle_mac.mm +++ b/src/plugins/styles/mac/qmacstyle_mac.mm @@ -5190,7 +5190,7 @@ void QMacStyle::drawComplexControl(ComplexControl cc, const QStyleOptionComplex break; if (isTransient) { - CGContextBeginTransparencyLayer(cg, NULL); + CGContextBeginTransparencyLayerWithRect(cg, scroller.frame, nullptr); CGContextSetAlpha(cg, opacity); }