测试修复首页闪屏问题
This commit is contained in:
parent
381d906bdc
commit
a40ba0ceb1
@ -416,6 +416,10 @@ public class CommonRefreshView extends FrameLayout implements View.OnClickListen
|
|||||||
mRecyclerView.addItemDecoration(gridSpacingItemDecoration);
|
mRecyclerView.addItemDecoration(gridSpacingItemDecoration);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public RecyclerView getRefreshView() {
|
||||||
|
return mRecyclerView;
|
||||||
|
}
|
||||||
|
|
||||||
public interface DataHelperNew {
|
public interface DataHelperNew {
|
||||||
void loadData(int p);
|
void loadData(int p);
|
||||||
|
|
||||||
|
@ -189,7 +189,7 @@ public class MainHomeLiveViewHolder extends AbsMainHomeChildViewHolder implement
|
|||||||
Log.i("t2", "aaa" + p);
|
Log.i("t2", "aaa" + p);
|
||||||
if (TextUtils.equals(typeHot, "Hot") || TextUtils.equals(typeHot, "hot") || TextUtils.equals(typeHot, "熱門")) {
|
if (TextUtils.equals(typeHot, "Hot") || TextUtils.equals(typeHot, "hot") || TextUtils.equals(typeHot, "熱門")) {
|
||||||
pp = 1;
|
pp = 1;
|
||||||
MainHttpUtil.getHot(p, callback);
|
// MainHttpUtil.getHot(p, callback);
|
||||||
LiveHttpUtil.getAnchorLastWeekList(new HttpCallback() {
|
LiveHttpUtil.getAnchorLastWeekList(new HttpCallback() {
|
||||||
@Override
|
@Override
|
||||||
public void onSuccess(int code, String msg, String[] info) {
|
public void onSuccess(int code, String msg, String[] info) {
|
||||||
@ -331,6 +331,8 @@ public class MainHomeLiveViewHolder extends AbsMainHomeChildViewHolder implement
|
|||||||
if (!canClick()) {
|
if (!canClick()) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
mRefreshView.getRefreshView().scrollToPosition(0);
|
||||||
|
mAdapter.clearData();
|
||||||
select = bean.getId();
|
select = bean.getId();
|
||||||
typeHot = bean.getEnglish();
|
typeHot = bean.getEnglish();
|
||||||
mRefreshView.initData();
|
mRefreshView.initData();
|
||||||
|
Loading…
Reference in New Issue
Block a user