diff options
Diffstat (limited to 'com/android/server/wm/AppWindowToken.java')
-rw-r--r-- | com/android/server/wm/AppWindowToken.java | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/com/android/server/wm/AppWindowToken.java b/com/android/server/wm/AppWindowToken.java index f19c554a..5676f588 100644 --- a/com/android/server/wm/AppWindowToken.java +++ b/com/android/server/wm/AppWindowToken.java @@ -1312,7 +1312,8 @@ class AppWindowToken extends WindowToken implements WindowManagerService.AppFree if (prevWinMode != WINDOWING_MODE_UNDEFINED && winMode == WINDOWING_MODE_PINNED) { // Entering PiP from fullscreen, reset the snap fraction mDisplayContent.mPinnedStackControllerLocked.resetReentrySnapFraction(this); - } else if (prevWinMode == WINDOWING_MODE_PINNED && winMode != WINDOWING_MODE_UNDEFINED) { + } else if (prevWinMode == WINDOWING_MODE_PINNED && winMode != WINDOWING_MODE_UNDEFINED + && !isHidden()) { // Leaving PiP to fullscreen, save the snap fraction based on the pre-animation bounds // for the next re-entry into PiP (assuming the activity is not hidden or destroyed) final TaskStack pinnedStack = mDisplayContent.getPinnedStack(); @@ -1714,7 +1715,8 @@ class AppWindowToken extends WindowToken implements WindowManagerService.AppFree adapter = new LocalAnimationAdapter( new WindowAnimationSpec(a, mTmpPoint, mTmpRect, mService.mAppTransition.canSkipFirstFrame(), - mService.mAppTransition.getAppStackClipMode()), + mService.mAppTransition.getAppStackClipMode(), + true /* isAppAnimation */), mService.mSurfaceAnimationRunner); if (a.getZAdjustment() == Animation.ZORDER_TOP) { mNeedsZBoost = true; @@ -1887,7 +1889,7 @@ class AppWindowToken extends WindowToken implements WindowManagerService.AppFree "AppWindowToken"); clearThumbnail(); - setClientHidden(hiddenRequested); + setClientHidden(isHidden() && hiddenRequested); if (mService.mInputMethodTarget != null && mService.mInputMethodTarget.mAppToken == this) { getDisplayContent().computeImeTarget(true /* updateImeTarget */); |