Instance Method

removeTitlebarAccessoryViewController(at:)

Removes the view controller at the specified index from the window’s array of title bar accessory view controllers.

Declaration

func removeTitlebarAccessoryViewController(at index: Int)

Parameters

index

The index in the array of title bar view controllers from which to remove the view controller.

Discussion

You can also use removeFromParent() to remove a specific title bar accessory view controller.

See Also

Managing the Toolbar-Title Bar Area

func addTitlebarAccessoryViewController(NSTitlebarAccessoryViewController)

Adds the specified title bar accessory view controller to the window.

func insertTitlebarAccessoryViewController(NSTitlebarAccessoryViewController, at: Int)

Inserts the view controller into the window’s array of title bar accessory view controllers at the specified index.

func performDrag(with: NSEvent)

Starts a drag based on the specified mouse-down event.

var titlebarAccessoryViewControllers: [NSTitlebarAccessoryViewController]

An array of title bar accessory view controllers that are currently added to the window.