android 设置View
回去window属性
WindowManager.LayoutParams l = r.window.getAttributes();
Decor 为PhoneWindow.DecorView 这个View其实是一个Activity 的最底层View
wm.addView(decor, l);
调用PhoneWindow的LocalWindowManager 中的addView
调用 WindowManagerImpl 的addView
进一步调用如下方法:final WindowManager.LayoutParams wparams = (WindowManager.LayoutParams)params;root.setView(view, wparams, panelParentView);
ViewRoot里面也有一个Window Attribute变量mWindowAttributes ---Window
attrs 为Window的Attribute mWindowAttributes.copyFrom(attrs);--ViewRoot
这是两个不同的对象,有时间内容相同。 具体看代码。