• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: dragging to trash folder problems
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: dragging to trash folder problems


  • Subject: Re: dragging to trash folder problems
  • From: "email@hidden" <email@hidden>
  • Date: Sun, 27 Dec 2009 10:19:04 -0800

kyle,
thanx for the response. see below for a followup question.

At 10:36 PM -0500 12/26/09, Kyle Sluder wrote:
On Sat, Dec 26, 2009 at 5:24 PM, email@hidden <email@hidden> wrote:
 however, if the user drags an object to the trash icon, and then
 subsequently drags to and drops on the (popped) opened trash folder, i no
 longer receive the NSDragOperationDelete operation in
 -draggedImage:endedAt:operation: and hence cannot detect that this should
 actually be a delete and the opened trash folder remains open on the
 desktop.

This sounds like a bug. You should file it at http://bugreport.apple.com. If the Dock is going to report a drag-to-Trash as a delete operation, then the Finder should report a drag-to-Trash-folder as a delete operation as well.

reported as 7499789


 1) how can i detect that the user dropped into a (popped) opened trash
 folder?

If you are able to drag to a folder at all, you must be providing a file or a promise pasteboard item. In that case, you should be able to tell if the destination folder is a Trash folder (either NSWorkspace or some Carbon API). Then you can perform the delete.

i am not providing either a file or a promise (at least not that i know of). in my table's data source implementation of -tableView:writeRowsWithIndexes:toPasteboard: i supply one (or more) private pboard types and i also provide NSRTFPboardType and NSStringPboardType data that enables dragging (rich) text to text files and which create text clipping files when dropped in a folder or on the desktop. for testing purposes, i implemented -tableView:setObjectValue:forTableColumn:row: and -pasteboard:provideDataForType: in my datasource, but neither is called.


ken
_______________________________________________

Cocoa-dev mailing list (email@hidden)

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:
This email sent to email@hidden


References: 
 >Re: dragging to trash folder problems (From: Kyle Sluder <email@hidden>)

  • Prev by Date: NSPopupButton & URLs
  • Next by Date: Re: Strange Problems with IBPlugin
  • Previous by thread: Re: dragging to trash folder problems
  • Next by thread: Compile errors with Objective-C++ properties as STL/TR1 smart pointers
  • Index(es):
    • Date
    • Thread