Instance Method


Invoked when a menu item is modified visually (for example, its title changes).


func itemChanged(_ item: NSMenuItem)



The menu item that has visually changed.


This method is not called for changes involving the menu item's action, target, represented object, or tag. Posts an didChangeItemNotification.

See Also

Adding and Removing Menu Items

func insertItem(NSMenuItem, at: Int)

Inserts a menu item into the menu at a specific location.

func addItem(NSMenuItem)

Adds a menu item to the end of the menu.

func addItem(withTitle: String, action: Selector?, keyEquivalent: String) -> NSMenuItem

Creates a new menu item and adds it to the end of the menu.

func removeItem(NSMenuItem)

Removes a menu item from the menu.

func removeItem(at: Int)

Removes the menu item at a specified location in the menu.

func removeAllItems()

Removes all the menu items in the menu.