开发者

UITableView - Automatic Load Next 25... when nearing bottom

Instead of the normal tap "Load Next 25..." at the bottom of a UITableView, I want the same loadNext: method to be called automatically as the user scrolls near to the bottom, so when the bottom is actua开发者_StackOverflow社区lly reached, the results will either already be there or a ActivitySpinner holding their place.

Does anybody know of an example that does this? I'd like to keep the behaviour consistent with any other apps that use a similar feature (similar to the "Pull down to refresh" behaviour we are seeing in many apps now).

Thanks


What I did in my app Think Messenger is add an extra row at the bottom of the table with an activity indicator. In my data source, whenever that cell is requested, I start downloading the next page of data.


Here's a post that goes step-by-step on how to do the 'pull to refresh' scheme. You can certainly repurpose it do it for the footer.

How to make a Pull-To-Reload TableView

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜