Class ListView
Events
onRefreshBefore
public Action onRefreshBefore
onItemAdded
public Action<T> onItemAdded
onItemRemoved
public Action<T> onItemRemoved
onItemSelected
public Action<T> onItemSelected
onSelectedIndexChanged
public Action<int> onSelectedIndexChanged
onItemSwapped
public Action<int, int> onItemSwapped
onDataChanged
public Action<IList<T>, IList<T>> onDataChanged
Properties
selectedItem
public T selectedItem { get; }
selectedIndex
public int selectedIndex { get; set; }
draggable
public bool draggable { get; private set; }
removable
public bool removable { get; private set; }
keyboardMoveEnabled
public bool keyboardMoveEnabled { get; private set; }
stripeItemStyleEnabled
public bool stripeItemStyleEnabled { get; private set; }
remainsHighlightedWhenLosingFocus
public bool remainsHighlightedWhenLosingFocus { get; set; }
itemMinHeight
public float itemMinHeight { get; private set; }
normalColor
public Color normalColor { get; set; }
highlightColor
public Color highlightColor { get; set; }
stripeItemColor
public Color stripeItemColor { get; set; }
data
public IList<T> data { get; private set; }
items
public IEnumerable<ListViewItem> items { get; }
itemDrawFunction
public Func<T, int, VisualElement> itemDrawFunction { get; private set; }
Methods
void Up()
public void Up()
void Down()
public void Down()
void AddItem(T item)
public void AddItem(T item)
void InsertItem(int index, T item)
public void InsertItem(int index, T item)
void SetData(IList<T> data, [bool refresh = true])
public void SetData(IList<T> data, [bool refresh = true])
void Refresh()
public void Refresh()
void ClearAllItem()
public void ClearAllItem()
bool RemoveItem(T item)
public bool RemoveItem(T item)
void RemoveItemAt(int index)
public void RemoveItemAt(int index)
ListViewItem GetItemElement(int index)
public ListViewItem GetItemElement(int index)
void SetSelectedIndexWithoutNotify(int value)
public void SetSelectedIndexWithoutNotify(int value)
void SetDraggable(bool draggable, [bool refresh = true])
public void SetDraggable(bool draggable, [bool refresh = true])
void SetRemovable(bool removable, [bool refresh = true])
public void SetRemovable(bool removable, [bool refresh = true])
void SetStripeItemStyle(bool enable, [bool refresh = true])
public void SetStripeItemStyle(bool enable, [bool refresh = true])
void SetKeyboardMoveEnabled(bool enable)
public void SetKeyboardMoveEnabled(bool enable)
void SetItemMinHeight(float itemMinHeight, [bool refresh = true])
public void SetItemMinHeight(float itemMinHeight, [bool refresh = true])
void SetItemDrawFunction(Func<T, int, VisualElement> itemDrawFunction, [bool refresh = true])
public void SetItemDrawFunction(Func<T, int, VisualElement> itemDrawFunction, [bool refresh = true])