Compile with -no-feature-cursor.
authorVolker Krause <volker.krause@kdab.com>
Fri, 30 Nov 2012 10:45:56 +0000 (11:45 +0100)
committerThe Qt Project <gerrit-noreply@qt-project.org>
Fri, 30 Nov 2012 16:06:37 +0000 (17:06 +0100)
Change-Id: I47fa7b978a8087086161b1e7bde2e0b2f91fd6e5
Reviewed-by: Sérgio Martins <sergio.martins.qnx@kdab.com>
Reviewed-by: Thomas McGuire <thomas.mcguire@kdab.com>
src/quick/items/qquickitem.cpp

index e557ce4..2340da9 100644 (file)
@@ -2186,9 +2186,11 @@ void QQuickItemPrivate::addChild(QQuickItem *child)
 
     childItems.append(child);
 
+#ifndef QT_NO_CURSOR
     QQuickItemPrivate *childPrivate = QQuickItemPrivate::get(child);
     if (childPrivate->extra.isAllocated())
         incrementCursorCount(childPrivate->extra.value().numItemsWithCursor);
+#endif
 
     markSortedChildrenDirty(child);
     dirty(QQuickItemPrivate::ChildrenChanged);
@@ -2207,9 +2209,11 @@ void QQuickItemPrivate::removeChild(QQuickItem *child)
     childItems.removeOne(child);
     Q_ASSERT(!childItems.contains(child));
 
+#ifndef QT_NO_CURSOR
     QQuickItemPrivate *childPrivate = QQuickItemPrivate::get(child);
     if (childPrivate->extra.isAllocated())
         incrementCursorCount(-childPrivate->extra.value().numItemsWithCursor);
+#endif
 
     markSortedChildrenDirty(child);
     dirty(QQuickItemPrivate::ChildrenChanged);