实现循环UITableView [英] implementing a cyclic UITableView
问题描述
实现循环UITableView的最佳方法是什么,而不是在用户向上滚动到表格边界时显示空格,它只是循环包裹?这里的示例可能是选择星期几,24小时工作小时,或者按顺序在全球范围内订购时区。有一些想法如何破解这个(可以说是从中间开始的100x7天的列表),但没有什么优雅。
What is the best way to implement a cyclic UITableView where instead of showing white space when the user scrolls up to the table's bounds, it simply wraps round cyclically? Examples here might be to pick the day of the week, hour in a 24 hour day, or the timezones ordered sequentially around the globe. Have a few ideas how to hack this (may be say a list of 100x7 days starting from the middle) but nothing elegant.
有没有人对此有任何想法或经验?
Does anyone have any ideas or experience of this?
David
推荐答案
你不能制作循环表。假设你从numberOfRowsInSection方法(有限数字)返回大量的行,那么也有一个上端和cource的表,你不能返回无限的行数,这就是为什么它有结束。所以它看起来不像圆桌。
You cant make cyclic table . suppose you return a large number of rows from numberOfRowsInSection method(finite number) then also table having a upper end and of cource you cant return infinite for number of rows thats why it having down end. so it cant look like round table.
你可以为有限的数字做它也可以重复行但是这不可能制作循环tableView。
you can do it for a finite number also you can repeat rows but this is not possible to make cyclic tableView.
这篇关于实现循环UITableView的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!