• 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: NSOutlineView and the trash can, take 2
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: NSOutlineView and the trash can, take 2


  • Subject: Re: NSOutlineView and the trash can, take 2
  • From: John Stiles <email@hidden>
  • Date: Wed, 3 Aug 2005 10:46:08 -0700

This code isn't working at all for me!! :( :(

I added it to my code and added some printfs to see if it was getting called--it was never reached. I always get outlineView:namesOfPromisedFilesDroppedAtDestination:forDraggedItems: instead.

I tried removing the outlineView:namesOfEtcEtc from my code, but then the NSOutlineView just threw an exception whenever I dragged files around.



On Aug 2, 2005, at 10:41 PM, Dominic Yu wrote:

2005/8/2, John Stiles <email@hidden>:

- drag items from the outline view into the Trash to delete them


You do use NSDragOperationDelete. Here's a snippet from one of my programs:


- (unsigned int)draggingSourceOperationMaskForLocal:(BOOL)isLocal {
return isLocal ? NSDragOperationNone :
NSDragOperationGeneric | NSDragOperationCopy | NSDragOperationDelete;
}


- (void)draggedImage:(NSImage *)anImage endedAt:(NSPoint)aPoint
operation:(NSDragOperation)operation {
    if (operation == NSDragOperationDelete) {
        // do deleting stuff here
    }
}

-Dominic


_______________________________________________ Do not post admin requests to the list. They will be ignored. Cocoa-dev mailing list (email@hidden) Help/Unsubscribe/Update your Subscription: This email sent to email@hidden
References: 
 >NSOutlineView and the trash can, take 2 (From: John Stiles <email@hidden>)
 >Re: NSOutlineView and the trash can, take 2 (From: Dominic Yu <email@hidden>)

  • Prev by Date: Does NSMatrix+NSArrayController work for custom cells?
  • Next by Date: Re: Exception handling help
  • Previous by thread: Re: NSOutlineView and the trash can, take 2
  • Next by thread: Re: NSOutlineView and the trash can, take 2
  • Index(es):
    • Date
    • Thread