i am using UICircularProgressView and have changed it to my liking. the initialization is clear but i'll post it anyways:
UICircularProgressView *wheelProgress = [[UICircularProgressView alloc]initWithFrame:CGRectMake(someFrame)];
then i am setting the right progress CGFloat between 0-1
CGFloat progress = .3; // example
[self.wheelProgress setProgress:progress];
This works just fine, and looks good, but i would really like to somehow animate it. I havent worked with animations so far, so my first approach was something like
for(tempProgress =! progress){
incrementing tempProgress
setting tempProgres to progressView
}
this of course is massively ugly and blocks everything else going on.
what i would like to achieve is a linear animation of the progress from 0 to its final value.
i have looked at: Animation tutorial
and came up with something like this:
CGContextRef context = UIGraphicsGetCurrentContext();
[UIView beginAnimations:nil context:context];
[UIView setAnimationCurve:UIViewAnimationCurveLinear];
[UIView setAnimationDuration: 1];
wheelProgress.progress = (progress) ? progress : 0.0;
[UIView commitAnimations];
but somehow this does not work..
any ideas what i need to fix here?
thanks in advance sebastian