Loading services/core/java/com/android/server/wm/ActivityTaskManagerService.java +0 −4 Original line number Diff line number Diff line Loading @@ -4048,10 +4048,6 @@ public class ActivityTaskManagerService extends IActivityTaskManager.Stub { mRecentTasks.notifyTaskPersisterLocked(task, flush); } boolean isKeyguardLocked(int displayId) { return mKeyguardController.isKeyguardLocked(displayId); } /** * Clears launch params for the given package. * Loading services/core/java/com/android/server/wm/KeyguardController.java +6 −10 Original line number Diff line number Diff line Loading @@ -423,7 +423,7 @@ class KeyguardController { final TransitionController tc = mRootWindowContainer.mTransitionController; final boolean occluded = isDisplayOccluded(displayId); final boolean occluded = getDisplayState(displayId).mOccluded; final boolean performTransition = isKeyguardLocked(displayId); final boolean executeTransition = performTransition && !tc.isCollecting(); Loading Loading @@ -500,15 +500,6 @@ class KeyguardController { } } /** * Returns {@code true} if the top activity on the display can occlude keyguard or the device * is dreaming. Note that this method may return {@code true} even if the keyguard is disabled * or not showing. */ boolean isDisplayOccluded(int displayId) { return getDisplayState(displayId).mOccluded; } ActivityRecord getTopOccludingActivity(int displayId) { return getDisplayState(displayId).mTopOccludesActivity; } Loading Loading @@ -601,6 +592,11 @@ class KeyguardController { private boolean mAodShowing; private boolean mKeyguardGoingAway; private boolean mDismissalRequested; /** * True if the top activity on the display can occlude keyguard or the device is dreaming. * Note that this can be true even if the keyguard is disabled or not showing. */ private boolean mOccluded; private boolean mShowingDream; Loading services/core/java/com/android/server/wm/RootWindowContainer.java +1 −1 Original line number Diff line number Diff line Loading @@ -2699,7 +2699,7 @@ class RootWindowContainer extends WindowContainer<DisplayContent> // transition exists, so this affects only when no lock screen is set. Otherwise // keyguard going away animation will be played. // See also AppTransitionController#getTransitCompatType for more details. if ((!mTaskSupervisor.getKeyguardController().isDisplayOccluded(display.mDisplayId) if ((!mTaskSupervisor.getKeyguardController().isKeyguardOccluded(display.mDisplayId) && token.mTag.equals(KEYGUARD_SLEEP_TOKEN_TAG)) || token.mTag.equals(DISPLAY_OFF_SLEEP_TOKEN_TAG)) { display.mSkipAppTransitionAnimation = true; Loading services/core/java/com/android/server/wm/Task.java +1 −1 Original line number Diff line number Diff line Loading @@ -3579,7 +3579,7 @@ class Task extends TaskFragment { && activity.info != info.taskInfo.topActivityInfo ? activity.info : null; info.isKeyguardOccluded = mAtmService.mKeyguardController.isDisplayOccluded(DEFAULT_DISPLAY); mAtmService.mKeyguardController.isKeyguardOccluded(info.taskInfo.displayId); info.startingWindowTypeParameter = activity.mStartingData != null ? activity.mStartingData.mTypeParams Loading services/tests/wmtests/src/com/android/server/wm/ActivityRecordTests.java +4 −3 Original line number Diff line number Diff line Loading @@ -1541,7 +1541,8 @@ public class ActivityRecordTests extends WindowTestsBase { // Make keyguard locked and set the top activity show-when-locked. KeyguardController keyguardController = activity.mTaskSupervisor.getKeyguardController(); int displayId = activity.getDisplayId(); doReturn(true).when(keyguardController).isKeyguardLocked(eq(displayId)); keyguardController.setKeyguardShown(displayId, true /* keyguardShowing */, false /* aodShowing */); final ActivityRecord topActivity = new ActivityBuilder(mAtm).setTask(task).build(); topActivity.setVisibleRequested(true); topActivity.nowVisible = true; Loading @@ -1553,7 +1554,7 @@ public class ActivityRecordTests extends WindowTestsBase { // Verify the stack-top activity is occluded keyguard. assertEquals(topActivity, task.topRunningActivity()); assertTrue(keyguardController.isDisplayOccluded(DEFAULT_DISPLAY)); assertTrue(keyguardController.isKeyguardOccluded(displayId)); // Finish the top activity topActivity.setState(PAUSED, "true"); Loading @@ -1562,7 +1563,7 @@ public class ActivityRecordTests extends WindowTestsBase { // Verify new top activity does not occlude keyguard. assertEquals(activity, task.topRunningActivity()); assertFalse(keyguardController.isDisplayOccluded(DEFAULT_DISPLAY)); assertFalse(keyguardController.isKeyguardOccluded(displayId)); } /** Loading Loading
services/core/java/com/android/server/wm/ActivityTaskManagerService.java +0 −4 Original line number Diff line number Diff line Loading @@ -4048,10 +4048,6 @@ public class ActivityTaskManagerService extends IActivityTaskManager.Stub { mRecentTasks.notifyTaskPersisterLocked(task, flush); } boolean isKeyguardLocked(int displayId) { return mKeyguardController.isKeyguardLocked(displayId); } /** * Clears launch params for the given package. * Loading
services/core/java/com/android/server/wm/KeyguardController.java +6 −10 Original line number Diff line number Diff line Loading @@ -423,7 +423,7 @@ class KeyguardController { final TransitionController tc = mRootWindowContainer.mTransitionController; final boolean occluded = isDisplayOccluded(displayId); final boolean occluded = getDisplayState(displayId).mOccluded; final boolean performTransition = isKeyguardLocked(displayId); final boolean executeTransition = performTransition && !tc.isCollecting(); Loading Loading @@ -500,15 +500,6 @@ class KeyguardController { } } /** * Returns {@code true} if the top activity on the display can occlude keyguard or the device * is dreaming. Note that this method may return {@code true} even if the keyguard is disabled * or not showing. */ boolean isDisplayOccluded(int displayId) { return getDisplayState(displayId).mOccluded; } ActivityRecord getTopOccludingActivity(int displayId) { return getDisplayState(displayId).mTopOccludesActivity; } Loading Loading @@ -601,6 +592,11 @@ class KeyguardController { private boolean mAodShowing; private boolean mKeyguardGoingAway; private boolean mDismissalRequested; /** * True if the top activity on the display can occlude keyguard or the device is dreaming. * Note that this can be true even if the keyguard is disabled or not showing. */ private boolean mOccluded; private boolean mShowingDream; Loading
services/core/java/com/android/server/wm/RootWindowContainer.java +1 −1 Original line number Diff line number Diff line Loading @@ -2699,7 +2699,7 @@ class RootWindowContainer extends WindowContainer<DisplayContent> // transition exists, so this affects only when no lock screen is set. Otherwise // keyguard going away animation will be played. // See also AppTransitionController#getTransitCompatType for more details. if ((!mTaskSupervisor.getKeyguardController().isDisplayOccluded(display.mDisplayId) if ((!mTaskSupervisor.getKeyguardController().isKeyguardOccluded(display.mDisplayId) && token.mTag.equals(KEYGUARD_SLEEP_TOKEN_TAG)) || token.mTag.equals(DISPLAY_OFF_SLEEP_TOKEN_TAG)) { display.mSkipAppTransitionAnimation = true; Loading
services/core/java/com/android/server/wm/Task.java +1 −1 Original line number Diff line number Diff line Loading @@ -3579,7 +3579,7 @@ class Task extends TaskFragment { && activity.info != info.taskInfo.topActivityInfo ? activity.info : null; info.isKeyguardOccluded = mAtmService.mKeyguardController.isDisplayOccluded(DEFAULT_DISPLAY); mAtmService.mKeyguardController.isKeyguardOccluded(info.taskInfo.displayId); info.startingWindowTypeParameter = activity.mStartingData != null ? activity.mStartingData.mTypeParams Loading
services/tests/wmtests/src/com/android/server/wm/ActivityRecordTests.java +4 −3 Original line number Diff line number Diff line Loading @@ -1541,7 +1541,8 @@ public class ActivityRecordTests extends WindowTestsBase { // Make keyguard locked and set the top activity show-when-locked. KeyguardController keyguardController = activity.mTaskSupervisor.getKeyguardController(); int displayId = activity.getDisplayId(); doReturn(true).when(keyguardController).isKeyguardLocked(eq(displayId)); keyguardController.setKeyguardShown(displayId, true /* keyguardShowing */, false /* aodShowing */); final ActivityRecord topActivity = new ActivityBuilder(mAtm).setTask(task).build(); topActivity.setVisibleRequested(true); topActivity.nowVisible = true; Loading @@ -1553,7 +1554,7 @@ public class ActivityRecordTests extends WindowTestsBase { // Verify the stack-top activity is occluded keyguard. assertEquals(topActivity, task.topRunningActivity()); assertTrue(keyguardController.isDisplayOccluded(DEFAULT_DISPLAY)); assertTrue(keyguardController.isKeyguardOccluded(displayId)); // Finish the top activity topActivity.setState(PAUSED, "true"); Loading @@ -1562,7 +1563,7 @@ public class ActivityRecordTests extends WindowTestsBase { // Verify new top activity does not occlude keyguard. assertEquals(activity, task.topRunningActivity()); assertFalse(keyguardController.isDisplayOccluded(DEFAULT_DISPLAY)); assertFalse(keyguardController.isKeyguardOccluded(displayId)); } /** Loading