From: Charles Yin Date: Tue, 29 May 2012 00:51:21 +0000 (+1000) Subject: Avoid using previously declared variables X-Git-Tag: 071012131707~271 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=631ae154ce69a19643ff355454a300cdf61b75a1;p=profile%2Fivi%2Fqtdeclarative.git Avoid using previously declared variables Change-Id: Ia4ba88bef012cee7329244adf10c219bd763a936 Reviewed-by: Michael Brasser --- diff --git a/src/qml/animations/qsequentialanimationgroupjob.cpp b/src/qml/animations/qsequentialanimationgroupjob.cpp index 12cce39..83860eb 100644 --- a/src/qml/animations/qsequentialanimationgroupjob.cpp +++ b/src/qml/animations/qsequentialanimationgroupjob.cpp @@ -368,10 +368,10 @@ void QSequentialAnimationGroupJob::animationRemoved(QAbstractAnimationJob *anim, // duration of the previous animations up to the current animation m_currentTime = 0; - for (QAbstractAnimationJob *anim = firstChild(); anim; anim = anim->nextSibling()) { - if (anim == m_currentAnimation) + for (QAbstractAnimationJob *job = firstChild(); job; job = job->nextSibling()) { + if (job == m_currentAnimation) break; - m_currentTime += animationActualTotalDuration(anim); + m_currentTime += animationActualTotalDuration(job); }