diff --git a/quickstep/src/com/android/quickstep/util/SurfaceTransactionApplier.java b/quickstep/src/com/android/quickstep/util/SurfaceTransactionApplier.java index 4757d4bc7d..1200208e30 100644 --- a/quickstep/src/com/android/quickstep/util/SurfaceTransactionApplier.java +++ b/quickstep/src/com/android/quickstep/util/SurfaceTransactionApplier.java @@ -75,6 +75,13 @@ public class SurfaceTransactionApplier extends ReleaseCheck { if (view == null) { return; } + Transaction t = new Transaction(); + for (int i = params.length - 1; i >= 0; i--) { + SurfaceParams surfaceParams = params[i]; + if (surfaceParams.surface.isValid()) { + surfaceParams.applyTo(t); + } + } mLastSequenceNumber++; final int toApplySeqNo = mLastSequenceNumber; @@ -85,13 +92,6 @@ public class SurfaceTransactionApplier extends ReleaseCheck { .sendToTarget(); return; } - Transaction t = new Transaction(); - for (int i = params.length - 1; i >= 0; i--) { - SurfaceParams surfaceParams = params[i]; - if (surfaceParams.surface.isValid()) { - surfaceParams.applyTo(t); - } - } mTargetViewRootImpl.mergeWithNextTransaction(t, frame); Message.obtain(mApplyHandler, MSG_UPDATE_SEQUENCE_NUMBER, toApplySeqNo, 0) .sendToTarget();