Seemingly Documentation confusion?
Seemingly Documentation confusion?
- Subject: Seemingly Documentation confusion?
- From: Michael de Haan <email@hidden>
- Date: Thu, 29 Oct 2009 04:58:21 -0700
I wonder if someone could explain the following.
In "NSDraggingDestination Protocol Reference (informal protocol)", it
states:
"The NSDraggingDestination informal protocol declares methods that
the destination object (or recipient) of a dragged image must
implement."
The methods ( which include )
- prepareForDragOperation: required method
- performDragOperation: required method
- concludeDragOperation: required method
are all marked as "required method".
However, in the " Drag and Drop Programming Topics for Cocoa" , in the
section " Receiving Drag Operations " the following is noted.
"When the image is dropped with a drag operation other than
NSDragOperationNone, the destination is sent a
prepareForDragOperation: message followed by performDragOperation:
andconcludeDragOperation:. You can cancel the drag by returning NO
from either of the first two methods.
You do the bulk of the data handling in the performDragOperation:
method; ***the other two methods are implemented only if
necessary***." (My emphasis)
In my test app, the latter statement seems to be true ie only
"performDragOperation:" seemed necessary to allow the drop.
Is this a contradiction, or my not following exactly what the
documentation is saying? (more likely :-) )
_______________________________________________
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