一个View的index越大,说明它越在上面
P.s.index为-1则在线性布局位于底部(-1具体原因不清楚)
addView
added in API level 1
public void addView (View child, int index, ViewGroup.LayoutParams params)
Adds a child view with the specified layout parameters.
Parameters | |
---|---|
child |
View : the child view to add
|
index |
int : the position at which to add the child or -1 to add last
|
p |