TraversalEdgeBehavior enum

Controls the transfer of focus beyond the first and the last items of a FocusScopeNode.

This enumeration only controls the traversal behavior performed by FocusTraversalPolicy. Other methods of focus transfer, such as direct calls to FocusNode.requestFocus and FocusNode.unfocus, are not affected by this enumeration.

See also:

Inheritance

Constructors

TraversalEdgeBehavior()
const

Values

closedLoop → const TraversalEdgeBehavior

Keeps the focus among the items of the focus scope.

Requesting the next focus after the last focusable item will transfer the focus to the first item, and requesting focus previous to the first item will transfer the focus to the last item, thus forming a closed loop of focusable items.

leaveFlutterView → const TraversalEdgeBehavior

Allows the focus to leave the FlutterView.

Requesting next focus after the last focusable item or previous to the first item will unfocus any focused nodes. If the focus traversal action was initiated by the embedder (e.g. the Flutter Engine) the embedder receives a result indicating that the focus is no longer within the current FlutterView. For example, NextFocusAction invoked via keyboard (typically the TAB key) would receive KeyEventResult.skipRemainingHandlers allowing the embedder handle the shortcut. On the web, typically the control is transferred to the browser, allowing the user to reach the address bar, escape an iframe, or focus on HTML elements other than those managed by Flutter.

Properties

hashCode int
The hash code for this object.
read-onlyinherited
index int
A numeric identifier for the enumerated value.
read-onlyinherited
runtimeType Type
A representation of the runtime type of the object.
read-onlyinherited

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited

Constants

values → const List<TraversalEdgeBehavior>
A constant List of the values in this enum, in order of their declaration.
[closedLoop, leaveFlutterView]