diff options
author | Qt Continuous Integration System <qt-info@nokia.com> | 2010-02-25 14:10:23 (GMT) |
---|---|---|
committer | Qt Continuous Integration System <qt-info@nokia.com> | 2010-02-25 14:10:23 (GMT) |
commit | 20aba4ffa2fdf7a7306424981049d430f7d88e5c (patch) | |
tree | e30e2351dab3d57e468462b45d53f40ce1e39f43 /src | |
parent | 39a1a94bfdb7878afb351101aead2fbdcc871a25 (diff) | |
parent | 8eaeb1d4415d19a43b20fffe46c2b29fd609bba1 (diff) | |
download | Qt-20aba4ffa2fdf7a7306424981049d430f7d88e5c.zip Qt-20aba4ffa2fdf7a7306424981049d430f7d88e5c.tar.gz Qt-20aba4ffa2fdf7a7306424981049d430f7d88e5c.tar.bz2 |
Merge branch '4.6' of scm.dev.nokia.troll.no:qt/oslo-staging-1 into 4.6-integration
* '4.6' of scm.dev.nokia.troll.no:qt/oslo-staging-1:
Revert changes made in scroll_sys().
Add benchmarks for accessing meta-object properties via QScriptValue
Diffstat (limited to 'src')
-rw-r--r-- | src/gui/kernel/qwidget_mac.mm | 14 |
1 files changed, 13 insertions, 1 deletions
diff --git a/src/gui/kernel/qwidget_mac.mm b/src/gui/kernel/qwidget_mac.mm index 9e7517f..f78596e 100644 --- a/src/gui/kernel/qwidget_mac.mm +++ b/src/gui/kernel/qwidget_mac.mm @@ -4475,8 +4475,20 @@ void QWidgetPrivate::scroll_sys(int dx, int dy, const QRect &r) } } + // ### Scroll the dirty regions as well, the following is not correct. + QRegion displayRegion = r.isNull() ? dirtyOnWidget : (dirtyOnWidget & r); + const QVector<QRect> &rects = dirtyOnWidget.rects(); + const QVector<QRect>::const_iterator end = rects.end(); + QVector<QRect>::const_iterator it = rects.begin(); + while (it != end) { + const QRect rect = *it; + const NSRect dirtyRect = NSMakeRect(rect.x() + dx, rect.y() + dy, + rect.width(), rect.height()); + [view setNeedsDisplayInRect:dirtyRect]; + ++it; + } + NSSize deltaSize = NSMakeSize(dx, dy); - [view translateRectsNeedingDisplayInRect:scrollRect by:deltaSize]; [view scrollRect:scrollRect by:deltaSize]; [view setNeedsDisplayInRect:deltaXRect]; [view setNeedsDisplayInRect:deltaYRect]; |