Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- on run {input, parameters}
- repeat with aFile in input
- tell application "Finder"
- try
- set origFile to original item of aFile
- set aWindow to make new Finder window
- set aWindow's target to origFile's parent
- select origFile
- end try
- end tell
- end repeat
- end run
- on new_tab()
- tell application "System Events" to tell application process "Finder"
- set frontmost to true
- tell front menu bar to tell menu "File" to tell menu item "New Tab"
- perform action "AXPress"
- end tell
- end tell
- end new_tab
- set testFiles to {alias "Macintosh HD:Users:Smokestack:Downloads:2b40e289.gif alias", ¬
- alias "Macintosh HD:Users:Smokestack:Downloads:image_20483_mirror.jpg alias"}
- tell application "Finder"
- if (folders open in new tabs of Finder preferences) is false then
- set folders open in new tabs of Finder preferences to true
- end if
- repeat with i from 1 to count of testFiles
- set thisItem to item i of testFiles
- set origFile to original item of thisItem
- reveal origFile
- select origFile
- end repeat
- end tell
Add Comment
Please, Sign In to add comment