decor view (containing the standard window frame/decorations and the client's content inside of that), which can be added as a window to the window manager.
Viewroot: root view
具体指的是什么,如何解释?

解决方案 »

  1.   

    我有一个window,如何遍历所有的view?
      

  2.   

    ActivityThread.java中调用wm.addView(decor, l);把它加入到window manager proxy的mViews中,同时为这个decor view创建一个ViewRoot,ViewRoot负责协调decor view与window manager直接绘图、事件处理。
    ViewRoot中有IWindowSession和IWindow用来和window manger打交道和接收window manager传过来的消息,消息传过来后ViewRoot分发给decor view,再由decor view进行分发
      

  3.   

    >>消息传过来后ViewRoot分发给decor view,再由decor view进行分发
    我看到的一些事件分发如key, touch都是viewroot直接分发给view,需要仔细看下
      

  4.   

    Retrieve the top-level window decor view (containing the standard window frame/decorations and the client's content inside of that), which can be added as a window to the window manager.
    Note that calling this function for the first time "locks in" various window characteristics as described in setContentView(View, android.view.ViewGroup.LayoutParams).