Do not skip onMovementBoundsChanged if already in PiP
If the Task is already in PiP mode and fixed rotation is happening, we still need the onMovementBoundsChanged callback to go through in PipTaskOrganizer. Note that there seems to be an existing bug that Launcher shelf height is ignored with the following steps - Enter PiP and open another app to fullscreen - Rotate screen and swipe the other app to home Video: http://recall/-/aaaaaabFQoRHlzixHdtY/gs08EEyHyNcn86lsIcbIRe Bug: 191143521 Test: follow the reproduce steps in bug, see the video Change-Id: I601c7493794316883445e9c69e5cdd6a808e8933
This commit is contained in:
@@ -828,11 +828,14 @@ public class PipTaskOrganizer implements ShellTaskOrganizer.TaskListener,
|
|||||||
WindowContainerTransaction wct) {
|
WindowContainerTransaction wct) {
|
||||||
// note that this can be called when swipe-to-home or fixed-rotation is happening.
|
// note that this can be called when swipe-to-home or fixed-rotation is happening.
|
||||||
// Skip this entirely if that's the case.
|
// Skip this entirely if that's the case.
|
||||||
if ((mInSwipePipToHomeTransition || mWaitForFixedRotation) && fromRotation) {
|
final boolean waitForFixedRotationOnEnteringPip = mWaitForFixedRotation
|
||||||
|
&& (mPipTransitionState.getTransitionState() != PipTransitionState.ENTERED_PIP);
|
||||||
|
if ((mInSwipePipToHomeTransition || waitForFixedRotationOnEnteringPip) && fromRotation) {
|
||||||
if (DEBUG) {
|
if (DEBUG) {
|
||||||
Log.d(TAG, "Skip onMovementBoundsChanged on rotation change"
|
Log.d(TAG, "Skip onMovementBoundsChanged on rotation change"
|
||||||
+ " mInSwipePipToHomeTransition=" + mInSwipePipToHomeTransition
|
+ " mInSwipePipToHomeTransition=" + mInSwipePipToHomeTransition
|
||||||
+ " mWaitForFixedRotation=" + mWaitForFixedRotation);
|
+ " mWaitForFixedRotation=" + mWaitForFixedRotation
|
||||||
|
+ " getTransitionState=" + mPipTransitionState.getTransitionState());
|
||||||
}
|
}
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user