AdvancedDropdownWidgetclass
A generic sliding hierarchical selector widget. Build a tree of `Editor.AdvancedDropdownItem` and hand it to this widget.
Constructors1
Showing 1 constructors
public AdvancedDropdownWidget(Editor.Widget parent)
| Parameter | Type | Description |
|---|---|---|
| parent | Widget | — |
No results match this filter.
Methods7
Showing 7 methods
protected virtual void BuildPanel(Editor.AdvancedDropdownWidget.AdvancedDropdownPanel panel)
Build a panel's content from the item tree. Override to customize.
| Parameter | Type | Description |
|---|---|---|
| panel | AdvancedDropdownPanel | — |
void—protected virtual void OnBuildSearchResults(Editor.AdvancedDropdownWidget.AdvancedDropdownPanel panel, string searchText)
Called after search results are populated. Override to add extra entries (e.g. "New Component" button).
| Parameter | Type | Description |
|---|---|---|
| panel | AdvancedDropdownPanel | — |
| searchText | string | — |
void—protected virtual void OnKeyRelease(Editor.KeyEvent e)
| Parameter | Type | Description |
|---|---|---|
| e | KeyEvent | — |
void—protected virtual void OnPaint()
void—public void PopPanel()
Pop the current panel (navigate back).
void—protected void PushPanel(Editor.AdvancedDropdownWidget.AdvancedDropdownPanel panel)
Push a new panel onto the stack (navigate deeper into a category).
| Parameter | Type | Description |
|---|---|---|
| panel | AdvancedDropdownPanel | — |
void—public void Rebuild()
Rebuild the item tree and reset to the root panel.
void—No results match this filter.
Properties13
Showing 13 properties
public Vector2 Editor.AdvancedDropdownWidget.ContentSize { get; set; }
Fixed size of the content area (below the search bar).
public Editor.Widget Editor.AdvancedDropdownWidget.FilterWidget { get; set; }
Optional filter widget placed next to the search bar (e.g. a settings button).
protected bool Editor.AdvancedDropdownWidget.IsSearching { get; set; }
Whether the user is currently searching.
bool—protected bool Editor.AdvancedDropdownWidget.IsTextInputActive { get; set; }
For subclasses that have a text input inside the panel (e.g. a name field) - set to true to prevent Left arrow key from popping the panel.
bool—protected Editor.Widget Editor.AdvancedDropdownWidget.Main { get; set; }
public System.Action`1<Editor.AdvancedDropdownItem> Editor.AdvancedDropdownWidget.OnBuildItems { get; set; }
Called to (re)build the item tree. Receives `Editor.AdvancedDropdownWidget.RootItem` after it has been cleared.
public System.Action Editor.AdvancedDropdownWidget.OnFinished { get; set; }
Called after selection to allow the host to close/cleanup.
Action—public System.Action`1<object> Editor.AdvancedDropdownWidget.OnSelect { get; set; }
Called when a leaf item is selected. Receives the item's `Editor.AdvancedDropdownItem.Value`.
Action<object>—public Editor.AdvancedDropdownItem Editor.AdvancedDropdownWidget.RootItem { get; set; }
The root of the item tree. Populated by `Editor.AdvancedDropdownWidget.OnBuildItems` or set directly.
public string Editor.AdvancedDropdownWidget.RootTitle { get; set; }
Title shown in the root panel header.
string—public Editor.LineEdit Editor.AdvancedDropdownWidget.Search { get; set; }
public string Editor.AdvancedDropdownWidget.SearchPlaceholderText { get; set; }
Placeholder text shown in the search bar.
string—public System.Func`3<Editor.AdvancedDropdownItem,string[],int> Editor.AdvancedDropdownWidget.SearchScorer { get; set; }
Optional custom search scorer. Receives an item and the search words, returns a score (0 = no match). If null, the default scorer matches against Title and Description.
No results match this filter.