I want to make application unactivable.
I mean its must be inactive and non-foreground even by click on it. Active window must be the same app as it was before click on my app.
How can I do this?
upd:
- Let's imagine some window/panel. Like a Dock. Let's call it "Docky"
Docky is inactive, Active window is Safari:
NSRunningApplicationSafari.isActive == true NSRunningApplicationDocky.isActive == false
I'm clicking on ANY empty point of Docky.
Expected result:
Safari is still active window. Like before click:
NSRunningApplicationSafari.isActive == true NSRunningApplicationDocky.isActive == false
Actual result:
Docky is active window, Safari is inactive:
NSRunningApplicationSafari.isActive == false NSRunningApplicationDocky.isActive == true
Another sample is Keyboard Viewer. You are clicking on the virtual keyboard, but active window is another app. Ant exactly active window getting keyPress events.