NSView dragImage:
NSView dragImage:
- Subject: NSView dragImage:
- From: Tom Waters <email@hidden>
- Date: Sat, 16 Jun 2001 17:47:36 -0700
Is NSView dragImage: not fully implemented?
From the documentation regarding the offset: parameter...
>
mouseOffset is the mouse's current location relative to the mouse-down
>
location. It determines the initial location of the image when dragging
>
commences. If you initiate a dragging operation immediately on a
>
mouse-down event, this should be (0.0, 0.0). If you test for a
>
mouse-dragged event first, this should be the difference between the
>
mouse-dragged event's location and that of the mouse-down event.
I have been setting the offset to the difference between the mouseDown
and the mouseDragged points given a small hysteresis, but it never seems
to make any difference.
As a test, I set the offset to 100, 100, yet it still doesn't adjust the
location of the dragged image at all.
[self dragImage: image
at: aPoint
offset: NSMakeSize(100,100)
event: theEvent
pasteboard: pboard
source: self
slideBack: YES];