是否可以找到ExpandableListView中的第一个可见项是GroupIndicator视图还是下面的childView?请帮忙
提前感谢
答案 0 :(得分:2)
最后设法做到了这一点
int firstVisibleItem = mExpListView.getFirstVisiblePosition();
long data = mExpListView.getExpandableListPosition(firstVisibleItem);
int type = mExpListView.getPackedPositionType(data);
if (type == ExpandableListView.PACKED_POSITION_TYPE_CHILD) {
Log.i("info", "childindicator");
}else
Log.i("info", "groupindicator");