public void SelectItem(CommandItem item) { if (SelectedItem == item) { return; } SelectedItem?.OnDeselected(); SelectedItem = item; item?.OnSelected(); OnItemSelected?.Invoke(item); }
private void OnItemSelected(CommandItem item) { var commandEditor = rootVisualElement.Q <VisualElement>("CommandEditor"); if (commandEditor == null) { return; } commandEditor.Clear(); if (item == null) { return; } var editor = item.Editor; var customCommandEditor = editor.CreateCommandEditorGUI(); commandEditor.Add(customCommandEditor); }
public CommandMovableManipulator(CommandItem item) { //if (target != item) throw new ArgumentException("Target must be CommandItem."); }
public WhileVariableCommandEditor(CommandItem commandItem, VisualElement customDetailRoot) : base(commandItem, customDetailRoot) { }
public WaitCommandEditor(CommandItem commandItem, VisualElement customDetailRoot) : base(commandItem, customDetailRoot) { }
public NestEventScriptCommandEditor(CommandItem commandItem, VisualElement customDetailRoot) : base(commandItem, customDetailRoot) { }
public EventCommandEditor(CommandItem commandItem, VisualElement customDetailRoot) { CommandItem = commandItem; CustomDetailRoot = customDetailRoot; }
public SkipContainerCommandEditor(CommandItem commandItem, VisualElement customDetailRoot) : base(commandItem, customDetailRoot) { }