ActiveMenuItemModel<T> class

Subclass of ActiveItemModel which converts a MenuModel instance into a list of MenuItem instances for use in the active list item management.

Inheritance

Constructors

ActiveMenuItemModel(IdGenerator idGenerator, {MenuModel<T>? menu, bool filterOutUnselectableItems = false})

Properties

activateFirstItemByDefault bool
Whether the first list item should activate whenever the changes.
getter/setter pairinherited
activeId String
ID of currently active item.
no setterinherited
activeItem → T?
Currently active item.
no setterinherited
hashCode int
The hash code for this object.
no setterinherited
items List<T>
Sets the item list, activating the first item, if the previously active item is not in the new list of items.
no getteroverride
no getter
modelChanged Stream
Stream of model change events
no setterinherited
peekNext → T?
Returns the next possible active item as if activeNext was called.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

activate(T value) → void
Activates value. If value is not found, the active pointer is set to none.
inherited
activateFirst() → void
Activates first element in the list.
inherited
activateLast() → void
Activates last element in the list.
inherited
activateNext() → void
Activates next element in the list, if the active item is not already the last item.
inherited
activatePrevious() → void
Activates previous element in the list, if the active item is not already the first item.
inherited
id(T? item) String
Returns an unique id for item.
inherited
isActive(T item) bool
Determines whether item is active.
inherited
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