I need some inspiration on how to build a nice progress bar for the iPhone. What I want to build is a custom progress bar, as I've drawn here:
alt text http://img.skitch.com/20100317-tf185nscpf41u1xp3s6fqbhux6.png
My approach up to now is to use a PNG (g开发者_JAVA百科ray in the figure above) with a transparent rounded rectangle. Through this rectangle, users see the moving bar. It would be nice to draw this bar with Quartz and give it a fancy animation (similar to the Mac OS X progress bars).
Any hints how to do this
you could use a couple nested UIViews and control the size of the childview and have different colors of backgrounds to show the progress or you could subclass the UIProgress bar like this example of the slide to unlock UISlider that has animation. The example is of a UISlider but the method used for animation could also be used on a progress bar without the difficulty of handling touches.
here is a link directly to the code from that discussion
精彩评论