public void SetEntitySelection(Entity entitySelection, TreeViewSelectionOptions options = TreeViewSelectionOptions.None) { if (entitySelection != Entity.Null && getWorldSelection().EntityManager.Exists(entitySelection)) { SetSelection(new List <int> { entitySelection.Index }, options); } }
public void SetSelection(IList <int> selectedIDs, TreeViewSelectionOptions options) { bool fireSelectionChanged = (options & TreeViewSelectionOptions.FireSelectionChanged) != 0; bool revealSelectionAndFrameLastSelected = (options & TreeViewSelectionOptions.RevealAndFrame) != 0; bool animatedFraming = false; m_TreeView.SetSelection(selectedIDs.ToArray(), revealSelectionAndFrameLastSelected, animatedFraming); if (fireSelectionChanged) { m_TreeView.NotifyListenersThatSelectionChanged(); } }
protected void SetSelection(IList <int> ids, TreeViewSelectionOptions options) { treeView.SetSelection(ids.Select(id => id + state.UniqueID).ToList(), options); }