We are notifying windows of resize as the frame moves (even though the
size does not change) during the pinned animation, confusing and
upsetting the client. We do want to notify it of the one resize
at the beginning or end of the animation, so we can't just block
reportResized on bounds animating. Luckily the other area that adds
windows to reportResized (Task) is smart enough to only do so if the
size has actually changed and not just movement, so we let those reports
go through and block ones initiating from here (which doesn't perform
a check that the size has actually changed).
Bug:
28559097
Change-Id: If1f983e7cc875175ce1d098c385478a9922dea67
void updateResizingWindows(final WindowState w) {
final WindowStateAnimator winAnimator = w.mWinAnimator;
if (w.mHasSurface && w.mLayoutSeq == mLayoutSeq && !w.isGoneForLayoutLw()) {
+ final Task task = w.getTask();
+ // In the case of stack bound animations, the window frames
+ // will update (unlike other animations which just modifiy
+ // various transformation properties). We don't want to
+ // notify the client of frame changes in this case. Not only
+ // is it a lot of churn, but the frame may not correspond
+ // to the surface size or the onscreen area at various
+ // phases in the animation, and the client will become
+ // sad and confused.
+ if (task != null && task.mStack.getBoundsAnimating()) {
+ return;
+ }
w.setInsetsChanged();
boolean configChanged = w.isConfigChanged();
if (DEBUG_CONFIGURATION && configChanged) {