How to show a window without stealing focus on macOS?
I was wondering how could spotlight floating with focus, and another window still has focus! I could easy make a window floating over all other window with window?.level = Int(CGWindowLevelForKey(.maximumWindow)) ,but I cannot let two windows both has focus, help! Is there any function like ShowWithoutActivating in Cocoa? I've been playing around with this a bit, and I seem to be able to produce this effect when the frontmost window is not from the same process as the frontmost application, which is what I suspect Spotlight is probably doing. I can achieve this like so: Set LSUIElement to YES