I'm trying to create a proxy app to provide touchbar functionality for an existing closed source app. I am able to communicate with the app through an api, but my touchbar disappears when it's not focused.
In the NSTouchBar
documentation it says:
On supported MacBook Pro models, the Touch Bar, above the keyboard, shows instances of the NSTouchBar class from the front-most app.
However, I am wondering if there is a way to force which touchbar is being displayed. I tried to not resign, which works somewhat, but then I lose focus from the application.
func applicationWillResignActive(_ notification: Notification) {
self.activate(ignoringOtherApps: true)
}