ReorderableListControlDefaultContextHandler Field |
Default functionality to handle context command.
Namespace: Rotorz.ReorderableListAssembly: Editor.ReorderableList (in Editor.ReorderableList.dll) Version: 0.0.0.0 (0.3.0.0)
Syntaxprotected static readonly MenuFunction2 DefaultContextHandler
protected static readonly var DefaultContextHandler : MenuFunction2
Field Value
Type:
MenuFunction2
ExamplesCan be used when adding custom items to the context menu:
protected override void AddItemsToMenu(GenericMenu menu, int itemIndex, IReorderableListAdaptor adaptor) {
var specialCommand = new GUIContent("Special Command");
menu.AddItem(specialCommand, false, defaultContextHandler, specialCommand);
}
function AddItemsToMenu(menu:GenericMenu, itemIndex:int, list:IReorderableListAdaptor) {
var specialCommand = new GUIContent('Special Command');
menu.AddItem(specialCommand, false, defaultContextHandler, specialCommand);
}
See Also