Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 6258a192 authored by Winson Chung's avatar Winson Chung
Browse files

Notify the remote animation runner if a remote transition is consumed

- It's possible a remote transition is merged into another transition
  or aborted, so we should notify the runner to clean up as well

Bug: 400838266
Flag: EXEMPT bugfix
Test: Presubmit + manual testing w/ app launch
Change-Id: Ia1b61ffdb783653f918580e2b272ac18b7958dc4
parent 0f3b1103
Loading
Loading
Loading
Loading
+11 −0
Original line number Diff line number Diff line
@@ -244,6 +244,17 @@ public abstract class RemoteAnimationRunnerCompat extends IRemoteAnimationRunner
                runner.onAnimationCancelled();
                finishRunnable.run();
            }

            @Override
            public void onTransitionConsumed(IBinder transition, boolean aborted)
                    throws RemoteException {
                // Notify the remote runner that the transition has been canceled if the transition
                // was merged into another transition or aborted
                synchronized (mFinishRunnables) {
                    mFinishRunnables.remove(transition);
                }
                runner.onAnimationCancelled();
            }
        };
    }