Insertion position constants
Used by addMenu(), addMenuItem(), and addSubMenu() to
specify the relative position of a newly created menu object
Public API
DIVIDER
Other constants
NO_ERROR
Error Codes from AppShell
menuData
Menu Data
Functions
_getMenuString
Return menu name with display key
_setupMainMenu
메인 메뉴를 셋팅한다.
Public API
addMenu
Add Menu
id
string,Command
Unique identifier for Menu. Typically use the id of command corresponding the menu.
position
nullablestring
- constant defining the position of new MenuItem relative to other MenuItems. Values: - With no relativeID, use Menus.FIRST or LAST (default is LAST) - Relative to a command id, use BEFORE or AFTER (required) - Relative to a MenuSection, use FIRST_IN_SECTION or LAST_IN_SECTION (required)
relativeId
nullablestring
- command id. Required for all position constants except FIRST and LAST.
Public API
getAllMenus
Retrieves the map of all Menu objects.
Returns: Object.<string,Menu>
Map of All Menus.
Public API
getMenu
Retrieves the Menu object for the corresponding id.
id
string
Unique identifier or command id for Menu.
Returns: Menu
Menu Object
Public API
getMenuItem
Retrieves the MenuItem object for the corresponding id.
id
string
Unique identifier or command id for MenuItem.
Returns: MenuItem
MenuItem Object
Public API
removeMenu
Removes a top-level menu from the application menu bar which may be native or HTML-based.
id
non-nullablestring
Unique identifier for Menu. Typically use the id of command corresponding the menu.