NSToolbarDelegate
A set of optional methods you use to configure the toolbar and respond to changes.
Declaration
protocol NSToolbarDelegate : NSObjectProtocolOverview
Use the methods of NSToolbarDelegate to customize the behavior of your toolbars. You might use these methods to track the addition or removal of toolbar items, or use them to prevent someone from rearranging or removing specific items. Adopt this protocol in one of your custom objects and assign that object to the delegate property of the NSToolbar object you want to manage.
Topics
Adding and removing items
toolbar(_:itemForItemIdentifier:willBeInsertedIntoToolbar:)toolbarWillAddItem(_:)toolbarDidRemoveItem(_:)NSToolbar.Identifier