Merge "Don't ensure config for activity that is about to be invisible" into oc-dev
am: 2d008a5fc1
Change-Id: I1cee8d490faf07b8b593543b53694ede3f177f57
This commit is contained in:
@@ -97,6 +97,7 @@ import static com.android.server.am.ActivityStack.ActivityState.STOPPING;
|
|||||||
import static com.android.server.am.ActivityStack.LAUNCH_TICK;
|
import static com.android.server.am.ActivityStack.LAUNCH_TICK;
|
||||||
import static com.android.server.am.ActivityStack.LAUNCH_TICK_MSG;
|
import static com.android.server.am.ActivityStack.LAUNCH_TICK_MSG;
|
||||||
import static com.android.server.am.ActivityStack.PAUSE_TIMEOUT_MSG;
|
import static com.android.server.am.ActivityStack.PAUSE_TIMEOUT_MSG;
|
||||||
|
import static com.android.server.am.ActivityStack.STACK_INVISIBLE;
|
||||||
import static com.android.server.am.ActivityStack.STOP_TIMEOUT_MSG;
|
import static com.android.server.am.ActivityStack.STOP_TIMEOUT_MSG;
|
||||||
import static com.android.server.am.EventLogTags.AM_ACTIVITY_FULLY_DRAWN_TIME;
|
import static com.android.server.am.EventLogTags.AM_ACTIVITY_FULLY_DRAWN_TIME;
|
||||||
import static com.android.server.am.EventLogTags.AM_ACTIVITY_LAUNCH_TIME;
|
import static com.android.server.am.EventLogTags.AM_ACTIVITY_LAUNCH_TIME;
|
||||||
@@ -2269,6 +2270,20 @@ final class ActivityRecord extends ConfigurationContainer implements AppWindowCo
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Skip updating configuration for activity that are stopping or stopped.
|
||||||
|
if (state == STOPPING || state == STOPPED) {
|
||||||
|
if (DEBUG_SWITCH || DEBUG_CONFIGURATION) Slog.v(TAG_CONFIGURATION,
|
||||||
|
"Skipping config check stopped or stopping: " + this);
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Skip updating configuration for activity is a stack that shouldn't be visible.
|
||||||
|
if (stack.shouldBeVisible(null /* starting */) == STACK_INVISIBLE) {
|
||||||
|
if (DEBUG_SWITCH || DEBUG_CONFIGURATION) Slog.v(TAG_CONFIGURATION,
|
||||||
|
"Skipping config check invisible stack: " + this);
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
if (DEBUG_SWITCH || DEBUG_CONFIGURATION) Slog.v(TAG_CONFIGURATION,
|
if (DEBUG_SWITCH || DEBUG_CONFIGURATION) Slog.v(TAG_CONFIGURATION,
|
||||||
"Ensuring correct configuration: " + this);
|
"Ensuring correct configuration: " + this);
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user