Class StringListAdapterBase
List adapter providing strings only.
Constructors
| Name | Description |
|---|---|
this
()
|
create empty string list adapter. |
this
(items)
|
Init with array of string resource IDs. |
this
(items)
|
Init with array of unicode strings. |
this
(items)
|
Init with array of StringListValue. |
Fields
| Name | Type | Description |
|---|---|---|
_iconIds
|
string[] | |
_intIds
|
int[] | |
_items
|
UIStringCollection | |
_lastItemIndex
|
int | |
_states
|
uint[] | |
_stringIds
|
string[] | |
adapterChanged
|
Signal!(dcanvas.widgets.lists.OnAdapterChangeHandler) | Handle items change |
Properties
| Name | Type | Description |
|---|---|---|
itemCount[get]
|
int | returns number of widgets in list |
items[get]
|
const(UIStringCollection) | Access to items collection. |
items[set]
|
StringListAdapterBase | Replace items collection. |
wantKeyEvents[get]
|
bool | return true to receive keyboard events |
wantMouseEvents[get]
|
bool | return true to receive mouse events |
Methods
| Name | Description |
|---|---|
add
(item, index)
|
add new item |
add
(item, index)
|
add new string resource item |
add
(item, index)
|
add new raw dstring item |
clear
()
|
remove all items |
itemId
(index)
|
returns integer item id by index (if supported) |
itemState
(index)
|
return list item's state flags |
itemStringId
(index)
|
returns string item id by index (if supported) |
remove
(index)
|
remove item by index |
resetItemState
(index, flags)
|
reset one or more list item's state flags, returns updated state |
setItemState
(index, flags)
|
set one or more list item's state flags, returns updated state |
connect
(handler)
|
connect adapter change handler |
disconnect
(handler)
|
disconnect adapter change handler |
itemWidget
(index)
|
return list item widget by item index |
onThemeChanged
()
|
called when theme is changed |
updateViews
()
|
notify listeners about list items changes |
updateStatesLength
()
|
Aliases
| Name | Description |
|---|---|
~this
|