summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGabriel de Dietrich <gabriel.dedietrich@digia.com>2014-10-03 13:50:30 +0200
committerGabriel de Dietrich <gabriel.dedietrich@digia.com>2014-10-13 02:41:42 +0200
commite3bfd9bea65cc7a9e1742b0cb7ca9af22c42f730 (patch)
tree85f82776645665165e8e2716cf396be81b158b78
parent1910454fe00cce8b815b1abc0a18a04d3d387ccf (diff)
QMacStyle: Use NSRect instead of CGRect in drawNSViewInRect()v5.4.0-beta1
Change-Id: I90fd62dea377dfa9569d1730a67136c7a5dc6f82 Reviewed-by: Timur Pocheptsov <Timur.Pocheptsov@digia.com> Reviewed-by: Andy Shaw <andy.shaw@digia.com>
-rw-r--r--src/widgets/styles/qmacstyle_mac.mm6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/widgets/styles/qmacstyle_mac.mm b/src/widgets/styles/qmacstyle_mac.mm
index 82718eea7f..9347a6ea90 100644
--- a/src/widgets/styles/qmacstyle_mac.mm
+++ b/src/widgets/styles/qmacstyle_mac.mm
@@ -1897,11 +1897,11 @@ void QMacStylePrivate::drawNSViewInRect(NSView *view, const QRect &qtRect, QPain
[NSGraphicsContext setCurrentContext:[NSGraphicsContext
graphicsContextWithGraphicsPort:ctx flipped:YES]];
- CGRect rect = CGRectMake(qtRect.x() + 1, qtRect.y(), qtRect.width(), qtRect.height());
+ NSRect rect = NSMakeRect(qtRect.x() + 1, qtRect.y(), qtRect.width(), qtRect.height());
[backingStoreNSView addSubview:view];
- view.frame = NSRectFromCGRect(rect);
- [view drawRect:NSRectFromCGRect(rect)];
+ view.frame = rect;
+ [view drawRect:rect];
[view removeFromSuperviewWithoutNeedingDisplay];
[NSGraphicsContext restoreGraphicsState];