=========================
UPDATE: After several days googling and experiments, I have found the answers for most of those dumb questions. See the answers I submitted.
=========
What is the responsibility of Android Window?
Here are some questions:
- Is it responsible for collecting and dispatching the input?
- What is the relationship between the view and window? Same as the relationship between surface and window in DFB?
- What is the relationship between an activity and window? Will each Activity has a window?
- Is it possible to create a window from application ? And when it is necessary?
- Does Android support multi-window?
EDIT: Add more questions:
What is responsibilities of various class , such as Window, View, Canvas, Surface and how they collaborate with each other?
How many windows usually an Activity have?
3.Will all the views in one Activity will be attached to Window? What does attach mean?
Every window have surface? Every Canvas has surface?
View is responsible for focus/keyEvent/ manager, while Cavus is only responsible for "drawing" operation.
WindowManager is responsible for Window stacking? How that is related with SurfaceFlinger?
View doesn't own a Surface , the Window the view contained owns?
The View draw itself using canvas got by calling surface.lockCanvas().
When onDraw(Canvas) will be called? How & who pass the canvas parameters?
Does Canvas has size? Will Window's surface always be full screen?
EDIT again:
After watching this wonderful presentatin provided by Romain Guy http://www.youtube.com/watch?v=duefsFTJXzc&feature=feedwll&list=WL , several questions are resolved and add several more :)
- Will every Activity has one ViewRoot and thus one Window?
- Is there any need to create a window explictly? and Will the surface for the window always be full screen?
- Will status bar be in another Window?
- What is the size of the surface? Will that always be full screen?