Android7.0中文文档(API)-- ViewAnimator
2017-06-08 17:07
651 查看
完整内容,请查看:http://www.zhdoc.net/android/reference/android/widget/ViewAnimator.html
ViewAnimator
public class ViewAnimator
extends FrameLayout
java.lang.Object | ||||
↳ | android.view.View | |||
↳ | android.view.ViewGroup | |||
↳ | android.widget.FrameLayout | |||
↳ | android.widget.ViewAnimator |
已知的直接子类 ViewFlipper, ViewSwitcher |
已知的间接子类 ImageSwitcher, TextSwitcher |
FrameLayoutcontainer that will perform animations when switching between its views.
FrameLayout容器的基类,它可以在视图之间转换时执行动画。
摘要
XML属性 | |
---|---|
android:animateFirstView | 设定当首次显示ViewAnimation时,是否对当前view呈现动画效果。 |
android:inAnimation | 当视图被显示时,呈现动画效果的动画。 |
android:outAnimation | 当视图被隐藏时,呈现动画效果的动画。 |
继承XML属性 |
---|
From class android.widget.FrameLayout |
From class android.view.ViewGroup |
From class android.view.View |
继承常量 |
---|
From class android.view.ViewGroup |
From class android.view.View |
继承字段 |
---|
From class android.view.View |
Public构造方法 |
---|
ViewAnimator(Context context) |
ViewAnimator(Context context, AttributeSet attrs) |
Public方法 | |
---|---|
void | addView(View child, int index, ViewGroup.LayoutParams params) Adds a child view with the specified layout parameters. 添加具有指定布局参数的子视图。 |
CharSequence | getAccessibilityClassName() Return the class name of this object to be used for accessibility purposes. 返回此对象的类名,用于辅助功能目的。 |
boolean | getAnimateFirstView() Returns whether the current View should be animated the first time the ViewAnimator is displayed. 返回当前视图在ViewAnimator第一次显示时,是否进行动画。 |
int | getBaseline() Return the offset of the widget's text baseline from the widget's top boundary. 返回widget文本基线的偏移,其从widget的顶部边界开始。 |
View | getCurrentView() Returns the View corresponding to the currently displayed child. 返回与当前显示的子项相对应的视图。 |
int | getDisplayedChild() Returns the index of the currently displayed child view. 返回当前显示的子视图的索引。 |
Animation | getInAnimation() Returns the current animation used to animate a View that enters the screen. 返回当前Animation对象,其对进入屏幕的视图进行动画。 |
Animation | getOutAnimation() Returns the current animation used to animate a View that exits the screen. 返回当前Animation对象,其对退出屏幕的视图进行动画。 |
void | removeAllViews() Call this method to remove all child views from the ViewGroup. 调用此方法,从ViewGroup中移除所有的子视图。 |
void | removeView(View view) Note: do not invoke this method from draw(android.graphics.Canvas), onDraw(android.graphics.Canvas), dispatchDraw(android.graphics.Canvas)or any related method. 注意:请勿从 draw(android.graphics.Canvas), onDraw(android.graphics.Canvas), dispatchDraw(android.graphics.Canvas)或任何相关的方法,调用此方法。 |
void | removeViewAt(int index) Removes the view at the specified position in the group. 移除ViewGroup中指定索引位置的视图。 |
void | removeViewInLayout(View view) Removes a view during layout. 在布局时,移除一个视图。 |
void | removeViews(int start, int count) Removes the specified range of views from the group. 从组中移除特定范围的视图。 |
void | removeViewsInLayout(int start, int count) Removes a range of views during layout. 在布局时,移除特定范围的视图。 |
void | setAnimateFirstView(boolean animate) Indicates whether the current View should be animated the first time the ViewAnimator is displayed. 设置当前视图在ViewAnimator第一次显示时,是否进行动画。 |
void | setDisplayedChild(int whichChild) Sets which child view will be displayed. 设置要显示的子视图。 |
void | setInAnimation(Context context, int resourceID) Specifies the animation used to animate a View that enters the screen. 设置Animation对象,其对进入屏幕的视图进行动画。 |
void | setInAnimation(Animation inAnimation) Specifies the animation used to animate a View that enters the screen. 设置Animation对象,其对进入屏幕的视图进行动画。 |
void | setOutAnimation(Animation outAnimation) Specifies the animation used to animate a View that exit the screen. 设置Animation对象,其对退出屏幕的视图进行动画。 |
void | setOutAnimation(Context context, int resourceID) Specifies the animation used to animate a View that exit the screen. 设置Animation对象,其对退出屏幕的视图进行动画。 |
void | showNext() Manually shows the next child. 手动显示下一个子视图。 |
void | showPrevious() Manually shows the previous child. 手动显示上一个子视图。 |
继承方法 |
---|
From class android.widget.FrameLayout |
From class android.view.ViewGroup |
From class android.view.View |
From class java.lang.Object |
From interface android.view.ViewParent |
From interface android.view.ViewManager |
From interface android.graphics.drawable.Drawable.Callback |
From interface android.view.KeyEvent.Callback |
From interface android.view.accessibility.AccessibilityEventSource |
XML属性
android:animateFirstView
Defines whether to animate the current View when the ViewAnimation is first displayed.设定当首次显示ViewAnimation时,是否对当前view呈现动画效果。
完整内容,请查看:http://www.zhdoc.net/android/reference/android/widget/ViewAnimator.html
相关文章推荐
- Android7.0中文文档(API)-- HeaderViewListAdapter
- Android7.0中文文档(API)--- ViewSwitcher
- Android7.0中文文档(API) -- ActionMenuView.OnMenuItemClickListener
- Android7.0中文文档(API)--- MultiAutoCompleteTextView
- Android7.0中文文档(API)-- AutoCompleteTextView.Validator
- Android7.0中文文档(API) -- HorizontalScrollView
- Android7.0中文文档(API)-- AutoCompleteTextView.OnDismissListener
- Android7.0中文文档(API)--- AutoCompleteTextView
- Android7.0中文文档(API) --- CheckedTextView
- Android7.0中文文档(API)-- ActionMenuView.LayoutParams
- Android7.0中文文档(API)--- FrameLayout
- Android 3.0 r1中文API文档(104) —— ViewTreeObserver
- Android2.2 API 中文文档系列(5) —— View
- Android2.2 API中文文档——View
- Android2.2 API 中文文档系列(5) —— View详解
- Android7.0中文文档(API) --- MediaController
- Android7.0中文文档(API)--- TabHost
- TextView的API 中文文档
- Android2.2 API中文文档——View Android View的xml属性
- Android 3.0 r1 API中文文档(105) —— ViewParent