android.widget.ExpandableListView.getLastVisiblePosition()方法的使用及代码示例

x33g5p2x  于2022-01-19 转载在 其他  
字(1.7k)|赞(0)|评价(0)|浏览(134)

本文整理了Java中android.widget.ExpandableListView.getLastVisiblePosition()方法的一些代码示例,展示了ExpandableListView.getLastVisiblePosition()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。ExpandableListView.getLastVisiblePosition()方法的具体详情如下:
包路径:android.widget.ExpandableListView
类名称:ExpandableListView
方法名:getLastVisiblePosition

ExpandableListView.getLastVisiblePosition介绍

暂无

代码示例

代码示例来源:origin: androidquery/androidquery

int last = elv.getLastVisiblePosition();

代码示例来源:origin: lucid-lynxz/BlogSamples

@Override
public View getChildView(int groupPosition, int childPosition, boolean isLastChild, View convertView, ViewGroup parent) {
  ChildHolder childHolder = null;
  if (convertView == null) {
    childHolder = new ChildHolder();
    convertView = this.layoutInflater.inflate(R.layout.item_fl_child, null);
    childHolder.photo = (ImageView) convertView.findViewById(R.id.iv_friend);
    childHolder.tvName = (TextView) convertView.findViewById(R.id.tv_name);
    convertView.setTag(childHolder);
  } else {
    childHolder = (ChildHolder) convertView.getTag();
  }
  FriendBean child = this.childList.get(groupPosition).get(childPosition);
  childHolder.tvName.setText(child.name);
  /*
  * 延时加载图片
  * 这里计算得到的firstVisiblePosition等位置是包含groupItem以及childItem在内的整个列表组合顺序
  * */
  if (this.expandGroupIndex >= 0 && !isScrolling) {
    if (!TextUtils.isEmpty(child.photoUrl)
        && childPosition >= this.el.getFirstVisiblePosition()
        && childPosition <= this.el.getLastVisiblePosition()) {
      //todo: imageLoader加载图片
    }
  }
  return convertView;
}

代码示例来源:origin: com.googlecode.android-query/android-query

int last = elv.getLastVisiblePosition();

代码示例来源:origin: stackoverflow.com

flatPosition>_expandableListView.getLastVisiblePosition())
_expandableListView.post(new Runnable() {

相关文章

ExpandableListView类方法