Mailing Lists: Apple Mailing Lists

Image of Mac OS face in stamp
 
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Adding modern drag flavors



On Mar 27, 2007, at 17:06:05, Mike Kluev wrote:

On Mon, 26 Mar 2007 16:27:28, "Steve Mills" <email@hidden> wrote:

When adding data to a clipboard, will the Pasteboard manager (or the
CFDataRef object) work correctly if I create the CFDataRef with
CFDataCreateWithBytesNoCopy, and my data source goes away after
calling PasteboardPutItemFlavorData? Or do I need to use
CFDataCreate? I'm guessing CFDataRef can't know when it needs to copy
the bytes into its own internal buffer when my local copy has been
destructed, correct?

You may still keep going without making an extra copy if you wish: do the actual destruction of the underlying data bits from inside the bytesDeallocator of CFDataCreateWithBytesNoCopy.

Right, but then my "local" variable that is the source of the data could no longer be local.


_________________________________________________________
Steve Mills                              Me: 952-401-6255
Senior Software Architect                         MultiAd
email@hidden                       www.multi-ad.com


_______________________________________________ Do not post admin requests to the list. They will be ignored. Carbon-dev mailing list (email@hidden) Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/carbon-dev/email@hidden

This email sent to email@hidden
References: 
 >Re: Adding modern drag flavors (From: Mike Kluev <email@hidden>)



Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2007 Apple Inc. All rights reserved.