Merge "Fix sysui crash."
diff --git a/packages/SystemUI/src/com/android/systemui/recents/views/TaskView.java b/packages/SystemUI/src/com/android/systemui/recents/views/TaskView.java
index ab51d5f..a6bf8a4 100644
--- a/packages/SystemUI/src/com/android/systemui/recents/views/TaskView.java
+++ b/packages/SystemUI/src/com/android/systemui/recents/views/TaskView.java
@@ -341,11 +341,10 @@
 
         if (launchState.launchedFromAppWithThumbnail) {
             if (mTask.isLaunchTarget) {
+                ctx.postAnimationTrigger.increment();
                 // Immediately start the dim animation
                 animateDimToProgress(taskViewEnterFromAppDuration,
                         ctx.postAnimationTrigger.decrementOnAnimationEnd());
-                ctx.postAnimationTrigger.increment();
-
                 // Animate the action button in
                 fadeInActionButton(taskViewEnterFromAppDuration);
             } else {