> On Jan 19, 2015, at 10:34:37, Jerry Krinock <je...@ieee.org> wrote:
> 
> 
> 
> True, the documentation says that -[NSWorkspace 
> recycleURLs:completionHandler]  acts "in the same manner as the Finder”, but 
> they didn’t say “exactly”.
> 
> The way to get it to work exactly like Finder is to AppleScript the Finder.  
> This also gives you an additional “bonus” - the trash-can sound effect :)
> 
> See code in my method 
> -[NSFileManager(SomeMore)trashPath:scriptFinder:error_p:] which is in here:

I was thinking of doing it with AppleScript. Thanks. Perhaps Apple expects the 
application calling recycleURLs will keep track of the returned urls and put 
them on its own undo stack. That seems kinda goofy.

And in case anyone else runs across this thread and runs into "Application 
isn't running" errors, I needed to add AppleScript entitlements to my sandboxed 
app in order for this to work.

--
Steve Mills
Drummer, Mac geek


_______________________________________________

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Reply via email to