diff options
author | Marius Storm-Olsen <marius.storm-olsen@nokia.com> | 2009-11-06 11:04:15 (GMT) |
---|---|---|
committer | Marius Storm-Olsen <marius.storm-olsen@nokia.com> | 2009-11-09 11:10:52 (GMT) |
commit | 4ad31892d735e6f1a7afffbf0bf8028663855adb (patch) | |
tree | 39d1cddf14853c00c4f2b1f55e62f3835d2925a4 /src/gui/graphicsview | |
parent | 195f4b98fbf31a92e27be4533fc2ccae99372b82 (diff) | |
download | Qt-4ad31892d735e6f1a7afffbf0bf8028663855adb.zip Qt-4ad31892d735e6f1a7afffbf0bf8028663855adb.tar.gz Qt-4ad31892d735e6f1a7afffbf0bf8028663855adb.tar.bz2 |
API review: Rename numRects() -> rectCount()
QRegion::numRects() is marked obsolete.
Removed all usage of the old function inside Qt and test-cases.
Reviewed-by: Andreas Aardal Hanssen
Diffstat (limited to 'src/gui/graphicsview')
-rw-r--r-- | src/gui/graphicsview/qgraphicsscene.cpp | 2 | ||||
-rw-r--r-- | src/gui/graphicsview/qgraphicsview.cpp | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/src/gui/graphicsview/qgraphicsscene.cpp b/src/gui/graphicsview/qgraphicsscene.cpp index dc036f8..e28ab61 100644 --- a/src/gui/graphicsview/qgraphicsscene.cpp +++ b/src/gui/graphicsview/qgraphicsscene.cpp @@ -4149,7 +4149,7 @@ static void _q_paintIntoCache(QPixmap *pix, QGraphicsItem *item, const QRegion & QRect br = pixmapExposed.boundingRect(); // Don't use subpixmap if we get a full update. - if (pixmapExposed.isEmpty() || (pixmapExposed.numRects() == 1 && br.contains(pix->rect()))) { + if (pixmapExposed.isEmpty() || (pixmapExposed.rectCount() == 1 && br.contains(pix->rect()))) { pix->fill(Qt::transparent); pixmapPainter.begin(pix); } else { diff --git a/src/gui/graphicsview/qgraphicsview.cpp b/src/gui/graphicsview/qgraphicsview.cpp index c88f678..a880402 100644 --- a/src/gui/graphicsview/qgraphicsview.cpp +++ b/src/gui/graphicsview/qgraphicsview.cpp @@ -978,7 +978,7 @@ QList<QGraphicsItem *> QGraphicsViewPrivate::findItems(const QRegion &exposedReg // Step 2) If the expose region is a simple rect and the view is only // translated or scaled, search for items using // QGraphicsScene::items(QRectF). - bool simpleRectLookup = exposedRegion.numRects() == 1 && matrix.type() <= QTransform::TxScale; + bool simpleRectLookup = exposedRegion.rectCount() == 1 && matrix.type() <= QTransform::TxScale; if (simpleRectLookup) { return scene->items(exposedRegionSceneBounds, Qt::IntersectsItemBoundingRect, |