On Dec 7, 2010, at 3:16 AM, Gustavo Pizano wrote:

> Hello Guys..
> 
> I see, I have been using GCD and blocks but on somme OSX app I did before, 
> not on iPhone, I tough tit wasn't there... :P. 


Blocks/GCD are in iOS 4.0 and higher. Assuming you have a paid developer 
account, you may want to watch the relevant WWDC videos from last year.

> 
> SO, I from within the method( block) that makes all the saving process, I do 
> something like 
> 
>>>     dispatch_async(dispatch_get_main_queue(), ^{
>>>        // code executed on main thread goes here (i.e., updating the 
>>> progress indicator in your case
>>> 
>>>     });
> 
> 
> and update the progress indicator bar,  great im gonna try that..


Yes.


> 
> also I have the option to call from within the same method a  [<MyConotroller 
> With the Progress indicator> performSelectorinMainThread: 
> withObject:<NSNumber with the float value to add> waitUntilDone:NO];  
> 
> right?


Yes, ssuming the selector you pass (you left it out) takes the NSNumber and 
updates the progress bar.


> 
> 
> What about the saving operation improving its saving time?,  I will check 
> today what takes longer, if creating the thumbnial, or encoding the views,  
> maybe I shouldn't encode the whole view, but s just the image reference and 
> the transform matrix...  ?/ I will try that one also.


I didn't look at your code closely and don't have the other code around it to 
profile which part is taking so long. 

Dave


_______________________________________________

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 arch...@mail-archive.com

Reply via email to