diff options
author | Christoph Schleifenbaum <christoph.schleifenbaum@kdab.com> | 2012-08-23 18:36:57 +0200 |
---|---|---|
committer | Qt by Nokia <qt-info@nokia.com> | 2012-08-29 12:48:10 +0200 |
commit | e1f617128ca65aa6cb7381ef29deba791417c91e (patch) | |
tree | ce22d6813bd3c62292f2af36a7ae325a45d15c37 | |
parent | c0a43591dc024d92b713b2088d0c26d791368a67 (diff) |
Drawing fix for overlay scrollbars on Mac.
A wrong check lead to a scrollbar with value 0 never been draw. This is
the fix for it. Instead is has to be checked for a length of 0.
Change-Id: I0c4e2f7e0014074e3c22554bcbea0ebfc3122952
Reviewed-by: Toby Tomkins <toby.tomkins@nokia.com>
Reviewed-by: Sean Harmer <sean.harmer@kdab.com>
-rw-r--r-- | src/widgets/styles/qmacstyle_mac.mm | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/widgets/styles/qmacstyle_mac.mm b/src/widgets/styles/qmacstyle_mac.mm index d1e4231071..9ab1663385 100644 --- a/src/widgets/styles/qmacstyle_mac.mm +++ b/src/widgets/styles/qmacstyle_mac.mm @@ -5206,7 +5206,7 @@ void QMacStyle::drawComplexControl(ComplexControl cc, const QStyleOptionComplex [scroller setFrame:NSMakeRect(0, 0, slider->rect.width(), height)]; CGContextTranslateCTM(cg, 0, value * totalHeight); } - if (value > 0.0) { + if (length > 0.0) { [scroller layout]; [scroller displayRectIgnoringOpacity:[scroller bounds] inContext:[NSGraphicsContext currentContext]]; |