OSDN Git Service

Clear task bounds data when removing non-bounds persistable task.
authorWale Ogunwale <ogunwale@google.com>
Mon, 9 Nov 2015 19:14:10 +0000 (11:14 -0800)
committerWale Ogunwale <ogunwale@google.com>
Mon, 9 Nov 2015 19:14:10 +0000 (11:14 -0800)
Bug: 25584169
Change-Id: Ie68fa12bf182e988077e6410197f7f497f839ba2

services/core/java/com/android/server/am/ActivityStack.java

index 6b8bdf8..ea0db6b 100644 (file)
@@ -4539,6 +4539,11 @@ final class ActivityStack {
         if (!moving) {
             mStackSupervisor.removeLockedTaskLocked(task);
             mWindowManager.removeTask(task.taskId);
+            if (!StackId.persistTaskBounds(mStackId)) {
+                // Reset current bounds for task whose bounds shouldn't be persisted so it uses
+                // default configuration the next time it launches.
+                task.updateOverrideConfiguration(null);
+            }
         }
 
         final ActivityRecord r = mResumedActivity;