abstract class webfwt::WebList
sys::Obj fwt::Widget fwt::Pane webfwt::WebList
@Js
WebList displays a set of objects as a List.
- index
-
Get the index for the given item. By default, items are matched to indices by
Obj.equals
. - items
-
Obj[] items
Items to display for this list. Defaults to an empty list.
- multi
-
Bool multi := false
Enable multiple selection. Defaults to
false
for single selection. - onAction
-
EventListeners onAction()
Callback when an item is double-clicked.
Event.index
: index of selected itemEvent.data
: the selected item
- onBeforeSelect
-
EventListeners onBeforeSelect()
Callback before an item is selected. To cancel the following selection event, set
Event.data
to the Str"cancel"
Event.index
: index of selected itemEvent.data
: the selected item
- onLayout
-
virtual override Void onLayout()
- onSelect
-
EventListeners onSelect()
Callback when an item is selected.
Event.index
: index of selected itemEvent.data
: the selected item
- prefSize
- prefh
-
Int? prefh := null
If non-null, reported for preferred width.
- prefw
-
Int? prefw := null
If non-null, reported for preferred width.
- selected
-
Obj[] selected := Obj[,]
Selected item, or null if no selection.
- selectedIndexes
-
Int[] selectedIndexes := Int[,]
Index of selected items, or empty list if no selection.