Preface
This chapter is about android. view. ViewManager. The version is Android 2.3 r1 and translated from "Aman". Welcome to his blog: http://blog.csdn.net/cocohufei. thank you again for "Aman "! I look forward to you join the Android Chinese translation group, contact my over140@gmail.com.
Statement
You are welcome to repost, but please keep the original source of the article :)
Blog Garden: http://www.cnblogs.com/
Android Chinese translation group: http://goo.gl/6vJQl
Body
I. Structure
Public interface ViewManager
Android. view. ViewManager
Indirect subclass
AbsListView, AbsSpinner, vertex, AdapterView <T extends Adapter>, AppWidgetHostView, DatePicker, DialerFilter, vertex, FrameLayout, Gallery, Gallery, GridView, vertex, ImageSwitcher, LinearLayout, ListView, MediaController, radioGroup, RelativeLayout, ScrollView, vertex, Spinner, TabHost, TabWidget, widget, TableRow, TextSwitcher, TimePicker, timer, ViewAnimator, ViewFlipper, ViewGroup, ViewSwitcher, WebView, WindowManager, and callback
Ii. Overview
This interface allows you to add and remove sub-views to and from an Activity. CallContext.getSystemService()
You can get an instance of this class. (Note: ViewManager is an interface without any implementation. The abstract class ViewGroup implements three methods of this interface .)
Iii. Public Methods
Public abstract voidAddView(View view, ViewGroup. LayoutParams params)
(Translator's note: Add a view object and specify its layout parameters .)
Parameters
View to specify the added subview
Layout parameters of the params subview)
Public abstract voidRemoveView(View view)
(Note: remove the specified view .)
Parameters
View specifies the child view to be removed)
Public abstract voidUpdateViewLayout(View view, ViewGroup. LayoutParams params)
(Translator's note: Updating the subview
Parameters
View specifies the updated subview.
Layout parameters used when params is updated)
Iv. Supplement
Article Selection
ViewManager Demo