Re: Detect Full Screen?
Re: Detect Full Screen?
- Subject: Re: Detect Full Screen?
- From: Bill Cheeseman <email@hidden>
- Date: Mon, 25 Jul 2011 10:15:27 -0400
On Jul 25, 2011, at 9:18 AM, Doug Adams wrote: tell application "Finder" set bigBounds to (get bounds of window of desktop) end tell
tell application "iTunes" set iBounds to (get bounds of front browser window) if bigBounds = iBounds then log "FULL SCREEN" else log "NOT FULL SCREEN" end if end tell
This is one of those rare cases where GUI Scripting is actually better:
tell application "System Events" tell process "Safari" -- or whatever get value of attribute "AXFullScreen" of window 1 end tell end tell display dialog result as text
You have to put the script in the Scripts folder and run it from the Scripts menu when the target window is in fact full screen. Running it from Script Editor in another space doesn't see the Safari window, as far as I can tell on a quick test.
|
_______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
Archives: http://lists.apple.com/archives/applescript-users
This email sent to email@hidden