ExpandableListView 设置默认展开
2014-03-17 11:22
225 查看
1、先实例化一个ExpandableListView对象,例如mExpandableListView
2、然后mExpandableListView.setAdapter(exlvAdapter);
3、//遍历所有group,将所有项设置成默认展开
int groupCount = mExpandableListView.getCount();
for (int i=0; i<groupCount; i++) {
mExpandableListView.expandGroup(i);
};
2、然后mExpandableListView.setAdapter(exlvAdapter);
3、//遍历所有group,将所有项设置成默认展开
int groupCount = mExpandableListView.getCount();
for (int i=0; i<groupCount; i++) {
mExpandableListView.expandGroup(i);
};
相关文章推荐
- 因虚拟光驱引发的困惑
- 九度OJ 1009 二叉搜索树
- 服务器向ios推送消息
- HDU1213 How Many Tables
- 编程回忆之Android回忆(Android Socket编程)
- javascript事件函数中获得事件源的两种不错方法
- 关于“CSDN发表不了博文”的解答——我的思索
- window.showModalDialog以及window.open用法简介
- python format格式化字符串
- CGI是什么?
- cmd下查看远程桌面端口
- AIX 是什么? AIX和UNIX的关系是什么
- 内部排序之一:插入排序和希尔排序的N中实现
- Android布局
- ibatis java.util.Map作为parameterClass和resultClass(转)
- Heritage from father
- IOMETER编译安装使用
- NIO
- 我多想有一位这样的朋友
- 值对象