Pause surface position for bounds change transaction
Currently the entering pip bounds is applied at the end of enter animation. There could be 2 flickering cases: 1. There is an offset from display cutout while the activity is fullscreen. The offset should be gone once the task no longer overlap with display cutout. But the position change applies before the app redraws. Which looks like shift left and then right in a short time. 2. Before the window frame is recomputed, the surface position is updated with pip bounds, e.g. (0,0)-(200,1000)=(-200,-1000). So this change updates the window surface position until the app has reported its draw transaction, and then applies them at once. Replaced mResizedWhileGone because it was never read for a long time. Bug: 331315278 Test: Assume the target app support auto-pip and it doesn't draw under display cutout. E.g. LAYOUT_IN_DISPLAY_CUTOUT_MODE_SHORT_EDGES Enter PiP from 90 degrees to home with 0 degrees. The pip content won't shift horizontally a few frames. Change-Id: I1cd79ccb05ac61edf37dffbbec8cfe37cb85b1f3 (cherry picked from commit c85f1ba3)
Loading
Please register or sign in to comment