Merge "Don't re-launch activities while the device is sleeping" into nyc-dev
This commit is contained in:
committed by
Android (Google) Code Review
commit
f6e3c9a553
@@ -18714,7 +18714,7 @@ public final class ActivityManagerService extends ActivityManagerNative
|
||||
starting = mainStack.topRunningActivityLocked();
|
||||
}
|
||||
|
||||
if (starting != null) {
|
||||
if (starting != null && starting.state != ActivityState.STOPPED) {
|
||||
kept = mainStack.ensureActivityConfigurationLocked(starting, changes, false);
|
||||
// And we need to make sure at this point that all other activities
|
||||
// are made visible with the correct configuration.
|
||||
|
||||
@@ -1820,7 +1820,8 @@ final class ActivityStack {
|
||||
boolean stackVisibleBehind, ActivityRecord visibleBehind,
|
||||
boolean behindFullscreenActivity) {
|
||||
|
||||
if (!okToShowLocked(r)) {
|
||||
if (!okToShowLocked(r)
|
||||
|| (mService.isSleepingOrShuttingDown() && r.voiceSession == null)) {
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user