Fix not callback onTaskMovedToFront when dismissing split
After I5dac8826e, launcher relies on onTaskMovedToFront to track the top
most task. But in wm-core, it doesn't invoke onTaskMovedToFront when
reparenting a leaf task to TaskDisplayArea, like when dismissing split
screen. This makes sure to cover such flow.
Fix: 229828519
Test: dismiss focused split side, enter overview, observed app icon is
correct.
Change-Id: Iaf420c8c7d80d3c80b2eeca31cad8718e541d8a1
This commit is contained in:
@@ -5997,6 +5997,9 @@ class Task extends TaskFragment {
|
||||
|
||||
if (canBeLaunchedOnDisplay(newParent.getDisplayId())) {
|
||||
reparent(newParent, onTop ? POSITION_TOP : POSITION_BOTTOM);
|
||||
if (isLeafTask()) {
|
||||
newParent.onLeafTaskMoved(this, onTop);
|
||||
}
|
||||
} else {
|
||||
Slog.w(TAG, "Task=" + this + " can't reparent to " + newParent);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user