Merge "Apply the transaction to the leash before it is sent to the client" into rvc-dev am: 3eea61dd1f
Change-Id: I34abf9149e4b9f186097da3f0218a7ac691e6e18
This commit is contained in:
@@ -266,7 +266,7 @@ class InsetsSourceProvider {
|
|||||||
if (getSource().getType() == ITYPE_IME) {
|
if (getSource().getType() == ITYPE_IME) {
|
||||||
setClientVisible(InsetsState.getDefaultVisibility(mSource.getType()));
|
setClientVisible(InsetsState.getDefaultVisibility(mSource.getType()));
|
||||||
}
|
}
|
||||||
final Transaction t = mDisplayContent.getPendingTransaction();
|
final Transaction t = mDisplayContent.mWmService.mTransactionFactory.get();
|
||||||
mWin.startAnimation(t, mAdapter, !mClientVisible /* hidden */,
|
mWin.startAnimation(t, mAdapter, !mClientVisible /* hidden */,
|
||||||
ANIMATION_TYPE_INSETS_CONTROL, null /* animationFinishedCallback */);
|
ANIMATION_TYPE_INSETS_CONTROL, null /* animationFinishedCallback */);
|
||||||
final SurfaceControl leash = mAdapter.mCapturedLeash;
|
final SurfaceControl leash = mAdapter.mCapturedLeash;
|
||||||
@@ -281,6 +281,9 @@ class InsetsSourceProvider {
|
|||||||
t.deferTransactionUntil(mWin.getSurfaceControl(), barrier, frameNumber);
|
t.deferTransactionUntil(mWin.getSurfaceControl(), barrier, frameNumber);
|
||||||
t.deferTransactionUntil(leash, barrier, frameNumber);
|
t.deferTransactionUntil(leash, barrier, frameNumber);
|
||||||
}
|
}
|
||||||
|
// Applying the transaction here can prevent the client from applying its transaction sooner
|
||||||
|
// than us which makes us overwrite the client's operation to the leash.
|
||||||
|
t.apply();
|
||||||
mControlTarget = target;
|
mControlTarget = target;
|
||||||
mControl = new InsetsSourceControl(mSource.getType(), leash,
|
mControl = new InsetsSourceControl(mSource.getType(), leash,
|
||||||
new Point(mWin.getWindowFrames().mFrame.left, mWin.getWindowFrames().mFrame.top));
|
new Point(mWin.getWindowFrames().mFrame.left, mWin.getWindowFrames().mFrame.top));
|
||||||
|
|||||||
Reference in New Issue
Block a user