Methods |
---|
Menu that covers most of the screen and hides more advanced UI elements and other features
- Source:
Methods
(static) addSeparator()
Add Separator to the menu header at current position (end) of the header labels
- Source:
(static) close()
Close the menu.
- Source:
(static) openMenu(atPluginId, toggle) → {boolean}
Open the Menu UI at desired tab
Parameters:
Name | Type | Description |
---|---|---|
atPluginId |
string | undefined | menu tab to open |
toggle |
boolean | whether to close if the menu is opened |
- Source:
Returns:
true if the menu was opened with this call
(static) openSubmenu(atPluginId, atSubId, toggle) → {boolean}
Open the Menu UI at desired sub-menu tab
Parameters:
Name | Type | Description |
---|---|---|
atPluginId |
string | menu tab to open |
atSubId |
string | undefined | sub-menu tab to open |
toggle |
boolean | whether to close if the menu is opened |
- Source:
Returns:
true if the submenu was opened by this call
(static) setMenu(ownerPluginId, toolsMenuId, title, html, icon, withSubmenu, container)
Add menu
Parameters:
Name | Type | Description |
---|---|---|
ownerPluginId |
string | context ID: the ID of plugin the menu belongs to e.g. should be called once if withSubmenu=false, the last call is the only menu shown under this ID e.g. can be called many times if withSubmenu=true, then all menus are treated as submenus |
toolsMenuId |
string | menu ID: should be unique ID in the DOM context |
title |
string | menu title as shown in the menu tab |
html |
string | menu content |
icon |
string | google icon tag |
withSubmenu |
boolean | true if the menu allows submenus: in that case, all added menus with the same owner ID are actually submenus |
container |
boolean | true if a common container should be added (i.e. margins/padding) |
- Source: