Friday, November 28, 2008

Not so new script for Space Toggle

Some guy from left nice comment with this script. This works better and is with elegance.

tell application "System Events"
tell expose preferences
tell spaces preferences
set spaceset to item 1 of (get properties as list)
set spaces enabled to (not (spaceset as boolean))
if spaceset is true then
say "Space turned off"
say "Space turned on"
end if
end tell
end tell
end tell
After upgrade to Snow Leopard this script didn't worked.
Later I found out 'item 1" should be modified to "item 5"

No comments: