Yes, CFRunLoopPerformBlock: works well! Thanks, -Carl > On Apr 22, 2016, at 4:09 PM, Clark Cox <clarkc...@gmail.com> wrote: > > If you really need the block to run in specific runloop modes, you can use > CFRunLoopPerformBlock: > > > > CFRunLoopPerformBlock(CFRunLoopGetMain(), kCFRunLoopCommonModes, ^{ > //Code to be performed on main thread > }); > > >> On Apr 22, 2016, at 16:00, Carl Hoefs <newsli...@autonomy.caltech.edu> wrote: >> >> On Apr 22, 2016, at 2:57 PM, Quincey Morris >> <quinceymor...@rivergatesoftware.com> wrote: >>> >>> If you must use performSelector, then you can write your own glue method >>> that takes an object parameter and invokes the API that takes the scalar >>> parameter. >> >> -performSelectorOnMainThread:withObject:waitUntilDone:modes: can handle >> NSRunLoopCommonModes, such as to ensure an animation continues to run in all >> run loop common modes. Does the block+GCD+dispatch_async approach support >> this, or is this a case where -performSelector: should be used? >> >> -Carl >> >> >> _______________________________________________ >> >> 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: >> https://lists.apple.com/mailman/options/cocoa-dev/clarkcox3%40gmail.com >> >> This email sent to clarkc...@gmail.com >
_______________________________________________ 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: https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to arch...@mail-archive.com