Re: Move files to second monitor
Re: Move files to second monitor
- Subject: Re: Move files to second monitor
- From: Deivy Marck Petrescu <email@hidden>
- Date: Sun, 1 Feb 2009 18:28:00 -0500
On Feb 1, 2009, at 4:39 PM, Roy McCoy wrote: Deivy Marck Petrescu wrote: I do confess that rereading the message I still do not get it. Basically, because If I wanted to move the icons I do it in 1 second via the finder, with a mouse!
That's kind of what I was thinking and saying too. There are, however, certain similarly simple operations - like dragging to the trash or ejecting a disk for example, and I have some others unique to my own situation - which are handy to have automated, and hence the normal system keycodes. If I were to be moving icons between monitors all the time, I think I too would want to automate that somehow.
I notice the Classic utility Desktop Resetter is now available for OS X, (halfway?) renamed as Desktility ( http://www.desktility.com/mac_more.html). I haven't been feeling the need for this as I did before, but it's only ten bucks so I might pick it up, and it might interest the guy who's moving his icons to a second monitor if he ever wants to move them back.
--- set p to path to "desk" as string tell application "Finder" set p to folder p tell p repeat with j in (get its every item) set l to get desktop position of (contents of j) --set desktop position of item j to {x, y} end repeat end tell end tell ---
Two questions:
(1) I don't get "set l to get desktop position of (contents of j)". That's in a repeat, so it would change every time through the loop unless I severely misunderstand. I don't understand its use, then.
(2) How does "set desktop position of item j to {x, y}" determine that the icon moves to the secondary monitor rather than the primary one? Can you do that with just "{x, y}"?
Thanks,
Roy, to answer question 1 run the following script and change the commented line between the two "return".
---- set l to {1, 2} repeat with j in l return j -- return (contents of j) end repeat --- j is a reference to 1. Contents of j is 1. Actually the following script would be better
-- set l to {1} repeat with j in l return j = 1 end repeat --
To answer question 2, put an icon in the second desktop and get its "desktop position". Then with that information you set "x" and "y" accordingly. The idea of the script was to give the initial pull to the OP.
|
_______________________________________________
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