Adapter的getView中可以设置: public static final int[] colors = new int[] { 0x3000000, 0x300010ff }; @Override public View getView(int position, View convertView, ViewGroup parent) { View view = super.getView(position, convertView, parent); int colorPos = position % colors.length; view.setBackgroundColor(colors[colorPos]); return view; } |