共用方式為


View.DrawableStateChanged Method

Definition

This function is called whenever the state of the view changes in such a way that it impacts the state of drawables being shown.

[Android.Runtime.Register("drawableStateChanged", "()V", "GetDrawableStateChangedHandler")]
protected virtual void DrawableStateChanged ();
[<Android.Runtime.Register("drawableStateChanged", "()V", "GetDrawableStateChangedHandler")>]
abstract member DrawableStateChanged : unit -> unit
override this.DrawableStateChanged : unit -> unit
Attributes

Remarks

This function is called whenever the state of the view changes in such a way that it impacts the state of drawables being shown.

If the View has a StateListAnimator, it will also be called to run necessary state change animations.

Be sure to call through to the superclass when overriding this function.

Java documentation for android.view.View.drawableStateChanged().

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to

See also