resizing image returned from NSDraggingInfo -draggedImage
resizing image returned from NSDraggingInfo -draggedImage
- Subject: resizing image returned from NSDraggingInfo -draggedImage
- From: edward taffel <email@hidden>
- Date: Sat, 12 Apr 2014 14:02:26 -0400
during inter-document drags of app objects, i’d like to resize the drag image to the mag (zoom) of an entered document.
this was easily accomplished in carbon. when i ported from carbon [in 2011] i tried what i considered obvious, e.g.
- (NSDragOperation)draggingEntered:(id < NSDraggingInfo >)sender {
NSImage* img= [sender draggedImage];
NSSize sz; // suitably initialized, of course
[img setSize:sz];
[img recache];
}
i was surprised when this did not work & reported it. i just noticed, engineering quietly closed the report [may 2013] w/ the suggestion that i investigate
enumerateDraggingItemsWithOptions: i’ve just had a look & this seems like very great bother to do something previously obtained w/ two lines of code.
does anyone have a workaround?
_______________________________________________
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