diff options
author | Dianne Hackborn <hackbod@google.com> | 2012-06-20 12:06:38 -0700 |
---|---|---|
committer | Android (Google) Code Review <android-gerrit@google.com> | 2012-06-20 12:06:38 -0700 |
commit | 0fa4d30b03c4307ca5d461aa4450b672b6850ea1 (patch) | |
tree | 9d95ba57363cd473b66fa77e525083d35fef8c91 /services | |
parent | b6ce1f311ce154af713ebc4f543fc2aaed446939 (diff) | |
parent | 6e2281d44c9b71a03a50ed24d654927111cd2b72 (diff) | |
download | frameworks_base-0fa4d30b03c4307ca5d461aa4450b672b6850ea1.zip frameworks_base-0fa4d30b03c4307ca5d461aa4450b672b6850ea1.tar.gz frameworks_base-0fa4d30b03c4307ca5d461aa4450b672b6850ea1.tar.bz2 |
Merge "Fix issue #6686339: 2 taps required to launch notification..." into jb-dev
Diffstat (limited to 'services')
3 files changed, 40 insertions, 15 deletions
diff --git a/services/java/com/android/server/wm/WindowManagerService.java b/services/java/com/android/server/wm/WindowManagerService.java index c329174..5cd4beb 100755 --- a/services/java/com/android/server/wm/WindowManagerService.java +++ b/services/java/com/android/server/wm/WindowManagerService.java @@ -9542,12 +9542,14 @@ public class WindowManagerService extends IWindowManager.Stub } } } - pw.println(); - if (mOpeningApps.size() > 0) { - pw.print(" mOpeningApps="); pw.println(mOpeningApps); - } - if (mClosingApps.size() > 0) { - pw.print(" mClosingApps="); pw.println(mClosingApps); + if (mOpeningApps.size() > 0 || mClosingApps.size() > 0) { + pw.println(); + if (mOpeningApps.size() > 0) { + pw.print(" mOpeningApps="); pw.println(mOpeningApps); + } + if (mClosingApps.size() > 0) { + pw.print(" mClosingApps="); pw.println(mClosingApps); + } } } @@ -9761,7 +9763,7 @@ public class WindowManagerService extends IWindowManager.Stub pw.print(" mTransitionWindowAnimationScale="); pw.print(mTransitionAnimationScale); pw.print(" mAnimatorDurationScale="); pw.println(mAnimatorDurationScale); pw.print(" mTraversalScheduled="); pw.print(mTraversalScheduled); - pw.print(" mNextAppTransition=0x"); + pw.print(" mNextAppTransition=0x"); pw.print(Integer.toHexString(mNextAppTransition)); pw.print(" mAppTransitionReady="); pw.println(mAppTransitionReady); pw.print(" mAppTransitionRunning="); pw.print(mAppTransitionRunning); @@ -9803,7 +9805,7 @@ public class WindowManagerService extends IWindowManager.Stub pw.println(mNextAppTransitionCallback); } pw.print(" mStartingIconInTransition="); pw.print(mStartingIconInTransition); - pw.print(", mSkipAppTransitionAnimation="); pw.println(mSkipAppTransitionAnimation); + pw.print(" mSkipAppTransitionAnimation="); pw.println(mSkipAppTransitionAnimation); } } @@ -9971,30 +9973,31 @@ public class WindowManagerService extends IWindowManager.Stub } synchronized(mWindowMap) { + pw.println(); if (dumpAll) { pw.println("-------------------------------------------------------------------------------"); } - dumpPolicyLocked(pw, args, dumpAll); + dumpLastANRLocked(pw); pw.println(); if (dumpAll) { pw.println("-------------------------------------------------------------------------------"); } - dumpSessionsLocked(pw, dumpAll); + dumpPolicyLocked(pw, args, dumpAll); pw.println(); if (dumpAll) { pw.println("-------------------------------------------------------------------------------"); } - dumpTokensLocked(pw, dumpAll); + dumpSessionsLocked(pw, dumpAll); pw.println(); if (dumpAll) { pw.println("-------------------------------------------------------------------------------"); } - dumpWindowsLocked(pw, dumpAll, null); + dumpTokensLocked(pw, dumpAll); pw.println(); if (dumpAll) { pw.println("-------------------------------------------------------------------------------"); } - dumpLastANRLocked(pw); + dumpWindowsLocked(pw, dumpAll, null); } } diff --git a/services/java/com/android/server/wm/WindowState.java b/services/java/com/android/server/wm/WindowState.java index 8f2ef76..f94bacd 100644 --- a/services/java/com/android/server/wm/WindowState.java +++ b/services/java/com/android/server/wm/WindowState.java @@ -719,6 +719,28 @@ final class WindowState implements WindowManagerPolicy.WindowState { } /** + * Like isReadyForDisplay(), but ignores any force hiding of the window due + * to the keyguard. + */ + boolean isReadyForDisplayIgnoringKeyguard() { + if (mRootToken.waitingToShow && + mService.mNextAppTransition != WindowManagerPolicy.TRANSIT_UNSET) { + return false; + } + final AppWindowToken atoken = mAppToken; + if (atoken == null && !mPolicyVisibility) { + // If this is not an app window, and the policy has asked to force + // hide, then we really do want to hide. + return false; + } + return mHasSurface && !mDestroying + && ((!mAttachedHidden && mViewVisibility == View.VISIBLE + && !mRootToken.hidden) + || mWinAnimator.mAnimation != null + || ((atoken != null) && (atoken.mAppAnimator.animation != null))); + } + + /** * Like isOnScreen, but returns false if the surface hasn't yet * been drawn. */ diff --git a/services/java/com/android/server/wm/WindowStateAnimator.java b/services/java/com/android/server/wm/WindowStateAnimator.java index 579cbb7..f2dd335 100644 --- a/services/java/com/android/server/wm/WindowStateAnimator.java +++ b/services/java/com/android/server/wm/WindowStateAnimator.java @@ -1218,10 +1218,10 @@ class WindowStateAnimator { } Slog.v(TAG, "performShow on " + this + ": mDrawState=" + mDrawState + " readyForDisplay=" - + mWin.isReadyForDisplay() + + mWin.isReadyForDisplayIgnoringKeyguard() + " starting=" + (mWin.mAttrs.type == TYPE_APPLICATION_STARTING), e); } - if (mDrawState == READY_TO_SHOW && mWin.isReadyForDisplay()) { + if (mDrawState == READY_TO_SHOW && mWin.isReadyForDisplayIgnoringKeyguard()) { if (SHOW_TRANSACTIONS || DEBUG_ORIENTATION) WindowManagerService.logSurface(mWin, "SHOW (performShowLocked)", null); if (DEBUG_VISIBILITY) Slog.v(TAG, "Showing " + this |