summaryrefslogtreecommitdiffstats
path: root/examples/widgets/widgets
diff options
context:
space:
mode:
authorShawn Rutledge <shawn.rutledge@qt.io>2017-05-03 14:24:57 +0200
committerShawn Rutledge <shawn.rutledge@qt.io>2017-06-02 20:31:16 +0000
commit4480f47f7b0f81483b0cf3c8327eff12938ca018 (patch)
tree361d0152680db37747474e1a7c4982c67530ffae /examples/widgets/widgets
parentc3797196074639a290672f061df81d14d936ff5b (diff)
tablet example: don't update the cursor image on iOS
There is no visible cursor on iOS, so updating the image is a waste of time. Removing this does in fact speed up rendering of the strokes. Change-Id: If958fabeefd4273644707277d4a084855d415bb1 Reviewed-by: Andy Shaw <andy.shaw@qt.io>
Diffstat (limited to 'examples/widgets/widgets')
-rw-r--r--examples/widgets/widgets/tablet/tabletcanvas.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/examples/widgets/widgets/tablet/tabletcanvas.cpp b/examples/widgets/widgets/tablet/tabletcanvas.cpp
index 778722cc41..7cae85e6e6 100644
--- a/examples/widgets/widgets/tablet/tabletcanvas.cpp
+++ b/examples/widgets/widgets/tablet/tabletcanvas.cpp
@@ -103,8 +103,10 @@ void TabletCanvas::tabletEvent(QTabletEvent *event)
}
break;
case QEvent::TabletMove:
+#ifndef Q_OS_IOS
if (event->device() == QTabletEvent::RotationStylus)
updateCursor(event);
+#endif
if (m_deviceDown) {
updateBrush(event);
QPainter painter(&m_pixmap);