Merge "Handle cancelled Insets animation" into rvc-qpr-dev am: e272df9338 am: 99813602c0

Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/12735138

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I556713d0fa14ab0f794eab49ac6c16b5354ed647
This commit is contained in:
Taran Singh
2021-02-05 18:19:30 +00:00
committed by Automerger Merge Worker

View File

@@ -111,6 +111,9 @@ public class InsetsAnimationThreadControlRunner implements InsetsAnimationContro
mControl = new InsetsAnimationControlImpl(controls, frame, state, listener,
types, mCallbacks, durationMs, interpolator, animationType, translator);
InsetsAnimationThread.getHandler().post(() -> {
if (mControl.isCancelled()) {
return;
}
Trace.asyncTraceBegin(Trace.TRACE_TAG_VIEW,
"InsetsAsyncAnimation: " + WindowInsets.Type.toString(types), types);
listener.onReady(mControl, types);