Re: Accepting the right file drops?
Re: Accepting the right file drops?
- Subject: Re: Accepting the right file drops?
- From: Scott Anguish <email@hidden>
- Date: Sun, 20 Oct 2002 04:31:40 -0400
On Sunday, October 20, 2002, at 03:56 AM, Lucas M. Haley wrote:
Hello all --
I am trying to get my document subclass to accept file drops from the
finder. In its init: method, I call registerForDraggedTypes: with
NSFilenamesPboardType.
But this seems to make the window accept _any_ kind of file. How do I
go about restricting it to only certain types (which are my own
defined doc types)? In the destination's draggingEntered: do I go
through all the documents dragged, and check for the type there? It
seems like there should be an easier way.
you don't specify what you're allowing the drops on.. but there are
protocols for validating a drop before it actually is done, and that's
where you can do the tests for the file types..
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.