Reputation: 31
Is there a way to find out if the user is in the Exposé mode? (i.e., all windows are being shown.) Thank you.
Upvotes: 3
Views: 214
Reputation: 96323
You don't need this information. If the user is not in Exposé, F11 (or fn-F11) will enter Exposé. If the user is already in Exposé, F11 (or fn-F11) will exit Exposé. So just send F11 (or fn-F11) unconditionally.
The real challenge is determining the correct key command to send. On a laptop or small Apple Wireless Keyboard, the command may include the fn modifier, but on a desktop machine with a full-size keyboard, the command will more probably be F11 alone. Furthermore, it's user-configurable.
The correct way to toggle Exposé programmatically is a separate question.
Upvotes: 0
Reputation: 61228
There's no public API for getting this information. What problem are you trying to solve?
Upvotes: 1