Re: Controlling window layering in Safari
Re: Controlling window layering in Safari
- Subject: Re: Controlling window layering in Safari
- From: Michael Terry <email@hidden>
- Date: Tue, 10 Feb 2004 11:55:59 -0800
On Feb 10, 2004, at 8:30 AM, Jeffrey H. Dean wrote:
Hello,
Can anyone explain how to control window layering in Safari. I have
tried to move a window whose id I know to the front with the following
but the index of the window remains unchanged.
set index of window id validateWindowId to 1
I looked into this awhile ago, and things didn't look good, and after
just checking, it doesn't seem as though much has changed.
Something like this almost works:
tell application "Safari"
move front document to back
end tell
but it actually duplicates the window (although not well).
This is the hack I used to move the last window to the front:
tell application "Safari"
repeat ((count windows) - 1) times
set window -1's index to 1
end repeat
end tell
but note that there's a bug. Safari only moves the window on a trial
basis. If you switch applications with the keyboard and come back,
Safari decides that you didn't *really* mean that you wanted to move
the window, and it considerately moves it to the back again. Luckily,
most of the time when you switch window ordering, you're planning on
clicking immediately on the front window, and that negates the problem
Mike
_______________________________________________
applescript-users mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/applescript-users
Do not post admin requests to the list. They will be ignored.