- child
- the child to attach
- index
- the index at which the child should be attached
- params
- the layout parameters of the child
Attaches a view to this view group. Attaching a view assigns this group as the parent, sets the layout parameters and puts the view in the list of children so that it can be retrieved by calling ViewGroup.GetChildAt(int).
This method is intended to be lightweight and makes no assumptions about whether the parent or child should be redrawn. Proper use of this method will include also making any appropriate View.RequestLayout or View.Invalidate calls. For example, callers can View.Post(Java.Lang.IRunnable) a Java.Lang.IRunnable which performs a View.RequestLayout on the next frame, after all detach/attach calls are finished, causing layout to be run prior to redrawing the view hierarchy.
This method should be called only for views which were detached from their parent.