Loading services/core/java/com/android/server/wm/ActivityRecord.java +1 −1 Original line number Diff line number Diff line Loading @@ -3589,7 +3589,7 @@ final class ActivityRecord extends WindowToken implements WindowManagerService.A @Override ActivityRecord getActivity(Predicate<ActivityRecord> callback, boolean traverseTopToBottom, WindowContainer boundary) { ActivityRecord boundary) { return callback.test(this) ? this : null; } Loading services/core/java/com/android/server/wm/ActivityStack.java +3 −1 Original line number Diff line number Diff line Loading @@ -2708,7 +2708,9 @@ class ActivityStack extends Task { */ @Nullable private ActivityRecord getOccludingActivityAbove(ActivityRecord activity) { return getActivity((ar) -> ar.occludesParent(), true /* traverseTopToBottom */, activity); ActivityRecord top = getActivity((ar) -> ar.occludesParent(), true /* traverseTopToBottom */, activity); return top != activity ? top : null; } boolean willActivityBeVisible(IBinder token) { Loading services/core/java/com/android/server/wm/WindowContainer.java +5 −3 Original line number Diff line number Diff line Loading @@ -1415,11 +1415,12 @@ class WindowContainer<E extends WindowContainer> extends ConfigurationContainer< } ActivityRecord getActivity(Predicate<ActivityRecord> callback, boolean traverseTopToBottom, WindowContainer boundary) { ActivityRecord boundary) { if (traverseTopToBottom) { for (int i = mChildren.size() - 1; i >= 0; --i) { final WindowContainer wc = mChildren.get(i); if (wc == boundary) return null; // TODO(b/156986561): Improve the correctness of the boundary check. if (wc == boundary) return boundary; final ActivityRecord r = wc.getActivity(callback, traverseTopToBottom, boundary); if (r != null) { Loading @@ -1430,7 +1431,8 @@ class WindowContainer<E extends WindowContainer> extends ConfigurationContainer< final int count = mChildren.size(); for (int i = 0; i < count; i++) { final WindowContainer wc = mChildren.get(i); if (wc == boundary) return null; // TODO(b/156986561): Improve the correctness of the boundary check. if (wc == boundary) return boundary; final ActivityRecord r = wc.getActivity(callback, traverseTopToBottom, boundary); if (r != null) { Loading Loading
services/core/java/com/android/server/wm/ActivityRecord.java +1 −1 Original line number Diff line number Diff line Loading @@ -3589,7 +3589,7 @@ final class ActivityRecord extends WindowToken implements WindowManagerService.A @Override ActivityRecord getActivity(Predicate<ActivityRecord> callback, boolean traverseTopToBottom, WindowContainer boundary) { ActivityRecord boundary) { return callback.test(this) ? this : null; } Loading
services/core/java/com/android/server/wm/ActivityStack.java +3 −1 Original line number Diff line number Diff line Loading @@ -2708,7 +2708,9 @@ class ActivityStack extends Task { */ @Nullable private ActivityRecord getOccludingActivityAbove(ActivityRecord activity) { return getActivity((ar) -> ar.occludesParent(), true /* traverseTopToBottom */, activity); ActivityRecord top = getActivity((ar) -> ar.occludesParent(), true /* traverseTopToBottom */, activity); return top != activity ? top : null; } boolean willActivityBeVisible(IBinder token) { Loading
services/core/java/com/android/server/wm/WindowContainer.java +5 −3 Original line number Diff line number Diff line Loading @@ -1415,11 +1415,12 @@ class WindowContainer<E extends WindowContainer> extends ConfigurationContainer< } ActivityRecord getActivity(Predicate<ActivityRecord> callback, boolean traverseTopToBottom, WindowContainer boundary) { ActivityRecord boundary) { if (traverseTopToBottom) { for (int i = mChildren.size() - 1; i >= 0; --i) { final WindowContainer wc = mChildren.get(i); if (wc == boundary) return null; // TODO(b/156986561): Improve the correctness of the boundary check. if (wc == boundary) return boundary; final ActivityRecord r = wc.getActivity(callback, traverseTopToBottom, boundary); if (r != null) { Loading @@ -1430,7 +1431,8 @@ class WindowContainer<E extends WindowContainer> extends ConfigurationContainer< final int count = mChildren.size(); for (int i = 0; i < count; i++) { final WindowContainer wc = mChildren.get(i); if (wc == boundary) return null; // TODO(b/156986561): Improve the correctness of the boundary check. if (wc == boundary) return boundary; final ActivityRecord r = wc.getActivity(callback, traverseTopToBottom, boundary); if (r != null) { Loading