final func activateItemByEvent(_ event: InputEvent?, forGlobalOnly: Bool = false) -> Bool
Checks the provided event against the PopupMenu’s shortcuts and accelerators, and activates the first item with matching events. If forGlobalOnly is true, only shortcuts and accelerators with global set to true will be called.
final func addIconRadioCheckShortcut(texture: Texture2D?, shortcut: Shortcut?, id: Int32 = -1, global: Bool = false)
Same as addIconCheckShortcut(texture:shortcut:id:global:), but uses a radio check button.
final func addIconShortcut(texture: Texture2D?, shortcut: Shortcut?, id: Int32 = -1, global: Bool = false, allowEcho: Bool = false)
Adds a new item and assigns the specified Shortcut and icon texture to it. Sets the label of the checkbox to the Shortcut’s name.
final func addSubmenuItem(label: String, submenu: String, id: Int32 = -1)
Adds an item that will act as a submenu of the parent PopupMenu node when clicked. The submenu argument must be the name of an existing PopupMenu that has been added as a child to this node. This submenu will be shown when the item is clicked, hovered for long enough, or activated using the ui_select or ui_right input actions.
final func addSubmenuNodeItem(label: String, submenu: PopupMenu?, id: Int32 = -1)
Adds an item that will act as a submenu of the parent PopupMenu node when clicked. This submenu will be shown when the item is clicked, hovered for long enough, or activated using the ui_select or ui_right input actions.