From 34e4a8ef6d20e829a322bfef1d09136a37fecfd2 Mon Sep 17 00:00:00 2001 From: Christian Ehrlicher Date: Fri, 7 Dec 2018 12:01:42 +0100 Subject: Cleanup Widgets examples - foreach Cleanup the Widgets examples - replace foreach with range-based for loop in the remaining directories Change-Id: I321e6c0f414401a1ae4fb65762b97d894b725afa Reviewed-by: Paul Wicking Reviewed-by: Luca Beldi --- examples/widgets/animation/sub-attaq/animationmanager.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'examples/widgets/animation/sub-attaq/animationmanager.cpp') diff --git a/examples/widgets/animation/sub-attaq/animationmanager.cpp b/examples/widgets/animation/sub-attaq/animationmanager.cpp index e3dc27f37f..a611641613 100644 --- a/examples/widgets/animation/sub-attaq/animationmanager.cpp +++ b/examples/widgets/animation/sub-attaq/animationmanager.cpp @@ -93,14 +93,14 @@ void AnimationManager::unregisterAllAnimations() void AnimationManager::pauseAll() { - foreach (QAbstractAnimation* animation, animations) { + for (QAbstractAnimation *animation : qAsConst(animations)) { if (animation->state() == QAbstractAnimation::Running) animation->pause(); } } void AnimationManager::resumeAll() { - foreach (QAbstractAnimation* animation, animations) { + for (QAbstractAnimation *animation : qAsConst(animations)) { if (animation->state() == QAbstractAnimation::Paused) animation->resume(); } -- cgit v1.2.3