Re: Drag and Drop in a NSView:Mouse coordinates
Re: Drag and Drop in a NSView:Mouse coordinates
- Subject: Re: Drag and Drop in a NSView:Mouse coordinates
- From: "John C. Randolph" <email@hidden>
- Date: Wed, 17 Apr 2002 12:37:05 -0700
On Wednesday, April 17, 2002, at 04:57 AM,
email@hidden wrote:
>
How can i get the coordinates of where an object is dropped in
>
a NSView?
The sender of any of the methods in the NSDraggingDestination
protocol conforms to NSDraggingInfo, so...
- (BOOL)performDragOperation:(id <NSDraggingInfo>)sender
{
NSPoint where = [sender draggingLocation];
NSLog(@"dragging concluded at (%d, %d)", where.x, where.y);
}
John C. Randolph <email@hidden> (408) 974-8819
Sr. Cocoa Software Engineer,
Apple Worldwide Developer Relations
http://developer.apple.com/cocoa/index.html
_______________________________________________
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.