diff --git a/live/src/main/java/com/yunbao/live/activity/LiveAudienceActivity.java b/live/src/main/java/com/yunbao/live/activity/LiveAudienceActivity.java index c0bdf86c8..71934ab26 100644 --- a/live/src/main/java/com/yunbao/live/activity/LiveAudienceActivity.java +++ b/live/src/main/java/com/yunbao/live/activity/LiveAudienceActivity.java @@ -215,6 +215,22 @@ public class LiveAudienceActivity extends LiveActivity { public void onPageScrolled(int position, float positionOffset, int positionOffsetPixels) { mCurrentItem = position; Log.e(TAG, "mCurrentItem:" + mCurrentItem); + if (mCurrentItem == itemModelList.size() - 1) { + MainNetManager.get(mContext) + .anchorRecommend("30", new com.yunbao.common.http.base.HttpCallback() { + @Override + public void onSuccess(AnchorRecommendModel data) { + + itemModelList.addAll(data.getList()); + mPagerAdapter.notifyDataSetChanged(); + } + + @Override + public void onError(String error) { + ToastUtil.show(error); + } + }); + } } @Override @@ -281,7 +297,7 @@ public class LiveAudienceActivity extends LiveActivity { mLiveUid = mLiveBean.getUid(); mStream = mLiveBean.getStream(); mAncherName = liveBean.getUserNiceName(); - Log.e("收到socket--->","mLiveUid--------------------------->"+mLiveUid); + Log.e("收到socket--->", "mLiveUid--------------------------->" + mLiveUid); //加载当前页面数据 View rootView = manager.getRootView(); if (rootView.getParent() != null && rootView.getParent() instanceof ViewGroup) {