pagerAdapter notifyDataSetChanged不刷新页面

转载自:maoyu417
这里只做记录。
private int mChildCount = 0;

 @Override
 public void notifyDataSetChanged() {         
       mChildCount = getCount();
       super.notifyDataSetChanged();
 }

 @Override
 public int getItemPosition(Object object)   {          
       if ( mChildCount > 0) {
       mChildCount --;
       return POSITION_NONE;
       }
       return super.getItemPosition(object);
 }

猜你喜欢

转载自blog.csdn.net/u013597998/article/details/80668094