Hey, is there some pattern or code to produce a carousel on the iphone? I need something like UIScrollView but that will loop when i scroll so that the first item is after the last item. people do that in javascript all the time, I'd like to do the same in objective-c.
+1
A:
What about a UIPickerView?. http://developer.apple.com/iPhone/library/documentation/UIKit/Reference/UIPickerView_Class/Reference/UIPickerView.html
hanno
2009-08-11 11:43:16
yeah, well, first UIPickerView looks like a UIPickerView, which sucks. and second, i also want to be able to use horizontal scrolling
Nir Levy
2009-08-11 11:57:09
A:
I'm not aware of any prepackaged plugins or established design patterns to achieve this, but I recently did it in an app for flicking through photos. Essentially, just build an array as a reference to whatever you're trying to iterate through, and then use UIImageViews with Quartz animations to handle the display. I've also heard of people hacking the functionality of a UIScrollView to achieve the same effect.
Somewhat of a vague answer, but it's likely just going to take digging into the code to get it right for your situation.
Mark Hammonds
2009-08-11 15:20:10