Re: NSOpenPanel problem
Re: NSOpenPanel problem
- Subject: Re: NSOpenPanel problem
- From: "Jan E. Schotsman" <email@hidden>
- Date: Mon, 23 Jan 2012 16:16:53 +0100
On Jan 23, 2012, at 11:37 AM, Conrad Shultz wrote:
You *really* need to read the docs on blocks and GCD since they are
the
"modern" way of writing threaded code, implementing callbacks, etc.
I'd
start with the "Short Practical Guide to Blocks" -
http://developer.apple.com/library/ios/#featuredarticles/
Short_Practical_Guide_Blocks/_index.html.
OK, will do that.
if I try to pass on someString in a C struct (contextInfo) then the
compiler complains that ARC doesn't like object pointers in C
structs.
I could serialize and unserialize the string. Or is there a better
way?
Just use the NSString * right in the block - no need for structs,
serialization, or anything. That's why blocks are so useful.
I still need an alternative because I want to support Leopard where
blocks aren't available. I've written some code using
NSPropertyListSerialization which should do the trick.
Jan E.
_______________________________________________
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