I have my UIElement
set to YES
in Info.plist
. Then I registered a hotkey. When it's pressed, it calls a NSWindowController
object and shows a window.
But I must call NSApp.activate(ignoringOtherApps: true)
after mainWindowController.showWindow(self)
, causing any other windows blur.
I want to create a window that does not change other window's status but can focus on (or receive local keyboard events), like what Alfred or Spotlight does.
When Alfred is called out, Chrome does not blur. When I hit my keyboard, I typed in Alfred instead of Chrome's input field.
When I press [ESC]
, Alfred hides. Chrome keeps activated and the text field is still focused on.