WindowManager的LayoutParams中窗口类型与定义:
frameworks\base\core\java\android\view\WindowManager.java
/**
-
Start of window types that represent normal application windows.
-
ZMS:首个普通应用窗口
*/
public static final int FIRST_APPLICATION_WINDOW = 1;
/**
-
Window type: an application window that serves as the “base” window
-
of the overall application; all other application windows will
-
appear on top of it.
-
In multiuser systems shows only on the owning user’s window.
-
ZMS:基础窗口-其他应用窗口会显示在此窗口之上
*/
public static final int TYPE_BASE_APPLICATION = 1;
/**
-
Window type: a normal application window. The {@link #token} must be
-
an Activity token identifying who the window belongs to.
-
In multiuser systems shows only on the owning user’s window.
-
ZMS:普通应用窗口-此窗口需要归属于Activity,多用户系统中仅仅在对应用户的窗口中显示
*/
public static final int TYPE_APPLICATION = 2;
/**
-
Window type: special application window that is displayed while the
-
application is starting. Not for use by applications themselves;
-
this is used by the system to display something until the
-
application can show its own windows.
-
In multiuser systems shows on all users’ windows.
-
ZMS:应用启动窗口-应用启动显示的窗口,不受应用本身控制。由系统在应用显示应用本身的窗口之前显示。
*/
public static final int TYPE_APPLICATION_STARTING = 3;
/**
-
End of types of application windows.
-
ZMS:终极应用窗口-所有Activity默认的窗口类型都是TYPE_APPLICATION,
-
WindowManagerService在进行窗口叠加时,会动态改变应用窗口的层值,但不会大于99。
*/
public static final int LAST_APPLICATION_WINDOW = 99;
/**
-
Start of types of sub-windows. The {@link #token} of these windows
-
must be set to the window they are attached to. These types of
-
windows are kept next to their attached window in Z-order, and their
-
coordinate spac