Method OnFocusChanged
OnFocusChanged(bool, FocusSearchDirection, Rect?)
Called by the view system when the focus state of this view changes.
protected override void OnFocusChanged(bool gainFocus, FocusSearchDirection direction, Rect? previouslyFocusedRect)
Parameters
gainFocusboolTrue if the View has focus; false otherwise.
directionFocusSearchDirectionThe direction focus has moved when requestFocus() is called to give this view focus. Values are
#FOCUS_UP,#FOCUS_DOWN,#FOCUS_LEFT,#FOCUS_RIGHT,#FOCUS_FORWARD, or#FOCUS_BACKWARD. It may not always apply, in which case use the default.previouslyFocusedRectRectThe rectangle, in this view's coordinate system, of the previously focused view. If applicable, this will be passed in as finer grained information about where the focus is coming from (in addition to direction). Will be
nullotherwise.
Remarks
Called by the view system when the focus state of this view changes. When the focus change event is caused by directional navigation, direction and previouslyFocusedRect provide insight into where the focus is coming from. When overriding, be sure to call up through to the super class so that the standard focus handling will occur.
.
android.view.View.onFocusChanged(boolean, int, android.graphics.Rect)
Portions of this page are modifications based on work created and shared by the