On Jun 20, 2008, at 4:00 PM, Grant Limberg wrote:

Currently, the user drags an existing image from their filesystem to an NSImageView bound to an NSData attribute in the sqlite data store. This causes the decompression from 1.5MB to 20MB. As you can see, this isn't exactly efficient. Hence the question on package/bundle creation. I'm wanting to just store the jpeg directly to disk and just store a URL to it in the sqlite data store.


You can always re-compress the image file before writing it out to the file system. But that seems kind of silly...

I would suggest that you intercept the drag operation and copy the file directly. You should be able to do this quite easily if you subclass the image view:

<http://developer.apple.com/documentation/Cocoa/Conceptual/DragandDrop/DragandDrop.html >

j o a r



_______________________________________________

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

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:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to [EMAIL PROTECTED]

Reply via email to