* commit 'e14afe7163a9d25c4d06e40165051f5c2d4d540a': The order of child windows is switched
This commit is contained in:
committed by
Android Git Automerger
commit
a998fa2df9
@@ -361,7 +361,32 @@ final class WindowState implements WindowManagerPolicy.WindowState {
|
||||
mSubLayer = mPolicy.subWindowTypeToLayerLw(a.type);
|
||||
mAttachedWindow = attachedWindow;
|
||||
if (WindowManagerService.DEBUG_ADD_REMOVE) Slog.v(TAG, "Adding " + this + " to " + mAttachedWindow);
|
||||
mAttachedWindow.mChildWindows.add(this);
|
||||
|
||||
int children_size = mAttachedWindow.mChildWindows.size();
|
||||
if (children_size == 0) {
|
||||
mAttachedWindow.mChildWindows.add(this);
|
||||
} else {
|
||||
for (int i = 0; i < children_size; i++) {
|
||||
WindowState child = (WindowState)mAttachedWindow.mChildWindows.get(i);
|
||||
if (this.mSubLayer < child.mSubLayer) {
|
||||
mAttachedWindow.mChildWindows.add(i, this);
|
||||
break;
|
||||
} else if (this.mSubLayer > child.mSubLayer) {
|
||||
continue;
|
||||
}
|
||||
|
||||
if (this.mBaseLayer <= child.mBaseLayer) {
|
||||
mAttachedWindow.mChildWindows.add(i, this);
|
||||
break;
|
||||
} else {
|
||||
continue;
|
||||
}
|
||||
}
|
||||
if (children_size == mAttachedWindow.mChildWindows.size()) {
|
||||
mAttachedWindow.mChildWindows.add(this);
|
||||
}
|
||||
}
|
||||
|
||||
mLayoutAttached = mAttrs.type !=
|
||||
WindowManager.LayoutParams.TYPE_APPLICATION_ATTACHED_DIALOG;
|
||||
mIsImWindow = attachedWindow.mAttrs.type == TYPE_INPUT_METHOD
|
||||
|
||||
Reference in New Issue
Block a user