applescript - Exit Full Screen menu bar item
Is it possible to click the Exit Full Screen menu bar item?
I cannot get a reference from Accessibility Inspector nor UI Browser.
MacBook Air, OS X Mountain Lion (10.8.4)
Apple Event: May 7th at 7 am PT
Is it possible to click the Exit Full Screen menu bar item?
I cannot get a reference from Accessibility Inspector nor UI Browser.
MacBook Air, OS X Mountain Lion (10.8.4)
Maybe you could use the Escape key, like this for example:
tell application "Safari" to activate
tell application "System Events" to key code 53
Maybe you could use the Escape key, like this for example:
tell application "Safari" to activate
tell application "System Events" to key code 53
That's not exactly what I'm asking for but thanks anyway. That works too.
Eventually I used the AXFullScreen attribute and this script.
tellapplication "System Events" totell (firstprocesswhosefrontmostistrue)
delay 0.05
if front window exists then
tell front window
if value of attribute "AXFullScreen" then
set value of attribute "AXFullScreen" to false
else
set value of attribute "AXFullScreen" to true
end if
end tell
end if
end tell
Nice!
applescript - Exit Full Screen menu bar item