Platforms to show: All Mac Windows Linux Cross-Platform
Back to CustomNSToolbarItemMBS class.
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
event | Cocoa Toolbar | MBS MacControls Plugin | 11.3 | ✅ Yes | ❌ No | ❌ No | ❌ No |
CustomNSToolbarItemMBS.allowsDuplicatesInToolbar as boolean
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
event | Cocoa Toolbar | MBS MacControls Plugin | 11.3 | ✅ Yes | ❌ No | ❌ No | ❌ No |
You use this event to override the default behavior in a subclass.
By default, if an item with the same identifier is already in the toolbar, dragging it in again will effectively move it to the new position.
If you leave this event empty (no code), you get the default behavior.
CustomNSToolbarItemMBS.validate as boolean
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
event | Cocoa Toolbar | MBS MacControls Plugin | 11.3 | ✅ Yes | ❌ No | ❌ No | ❌ No |
If this event is implemented and returns false, NSToolbar will disable theItem; returning true causes theItem to be enabled.
NSToolbar only calls this method for image items.
validateis called very frequently, so it must be efficient.
If you don't have code in this event, the plugin will simply return enabled value.
This methods may not be called if you set Autovalidates to true.
The items on this page are in the following plugins: MBS MacControls Plugin.