Skip to content
Permalink
Browse files

Automatically stop animation when it hits the start or end

  • Loading branch information
nyalldawson committed Mar 12, 2020
1 parent eef889a commit 1e4c252c97bdf9b09471b2b473e487502e8b0243
Showing with 4 additions and 0 deletions.
  1. +4 −0 src/core/qgstemporalnavigationobject.cpp
@@ -33,10 +33,14 @@ void QgsTemporalNavigationObject::timerTimeout()
{
case AnimationState::Forward:
next();
if ( mCurrentFrameNumber >= totalFrameCount() - 1 )
pause();
break;

case AnimationState::Reverse:
previous();
if ( mCurrentFrameNumber <= 0 )
pause();
break;

case AnimationState::Idle:

0 comments on commit 1e4c252

Please sign in to comment.
You can’t perform that action at this time.