如何使一个环形的ListView? [英] How to make a looped ListView?

查看:489
本文介绍了如何使一个环形的ListView?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

如何使一个循环的ListView ,这样的演出结束后,将最初的对象。
任何人都可以给决策参考或将它看起来应该像图片此菜单只迷恋。

How to make a looped ListView, such that after the end of the show will be the initial object. Can anyone give a reference to the decision or bring it should look something like this menu with pictures only fixated.

推荐答案

使用创建自己的适配器即 BaseAdapter 和在

create own adapter using i.e. BaseAdapter and inside

public class OwnAdapter extends BaseAdapter{

    ArrayList<Object> objects; //init by your own

    public int getCount() {
        return Integer.MAX_VALUE;
    }

    public Object getItem(int position) {
        return objects.get(position % object.size());
    }

    // and other abstract methods like getView etc.
}

这篇关于如何使一个环形的ListView?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆