summaryrefslogtreecommitdiffstats
path: root/examples/widgets/painting/pathstroke/main.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'examples/widgets/painting/pathstroke/main.cpp')
-rw-r--r--examples/widgets/painting/pathstroke/main.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/examples/widgets/painting/pathstroke/main.cpp b/examples/widgets/painting/pathstroke/main.cpp
index 3a63203118..57c85d73a3 100644
--- a/examples/widgets/painting/pathstroke/main.cpp
+++ b/examples/widgets/painting/pathstroke/main.cpp
@@ -63,8 +63,8 @@ int main(int argc, char **argv)
PathStrokeWidget pathStrokeWidget(smallScreen);
QStyle *arthurStyle = new ArthurStyle();
pathStrokeWidget.setStyle(arthurStyle);
- QList<QWidget *> widgets = pathStrokeWidget.findChildren<QWidget *>();
- foreach (QWidget *w, widgets) {
+ const QList<QWidget *> widgets = pathStrokeWidget.findChildren<QWidget *>();
+ for (QWidget *w : widgets) {
w->setStyle(arthurStyle);
w->setAttribute(Qt::WA_AcceptTouchEvents);
}