WindowManager: Gate pending-transaction behind sync
Developers will reasonably assume that commands placed in to sync or pending transaction in a given order will reach the screen in that order. For example in this sequence: 1. getSyncTransaction().hide(sc) 2. Time passes 3. getPendingTransaction.show(sc) we would expect the SurfaceControl to end up visible. However if the sync transaction were sent to SysUI but not yet applied it could end up applied after, in which case the final state of the SurfaceControl would be hidden. To solve this we listen to the transaction committed callback for sync transactions before sending the transaction to SysUI. In the interim time period we gate the pending transaction on this callback. Bug: 224438403 Bug: 227533765 Test: Existing tests pass Change-Id: I5a99d68e134c3f10970f4635514c1a83456c4217
Loading
Please register or sign in to comment