Skip to content

Commit

Permalink
fix bug
Browse files Browse the repository at this point in the history
  • Loading branch information
jdsjlzx committed Sep 20, 2016
1 parent a658cb8 commit 2ab0df0
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -362,7 +362,10 @@ public void onScrolled(int dx, int dy) {
public void onScrollStateChanged(int state) {
super.onScrollStateChanged(state);
currentScrollState = state;
mWrapAdapter.setScrollState(state);

if (mWrapAdapter != null) {
mWrapAdapter.setScrollState(state);
}

if (mLScrollListener != null) {
mLScrollListener.onScrollStateChanged(state);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -252,7 +252,10 @@ public void onScrolled(int dx, int dy) {
public void onScrollStateChanged(int state) {
super.onScrollStateChanged(state);
currentScrollState = state;
mWrapAdapter.setScrollState(state);

if (mWrapAdapter != null) {
mWrapAdapter.setScrollState(state);
}

if (mLScrollListener != null) {
mLScrollListener.onScrollStateChanged(state);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -304,8 +304,8 @@ public boolean onOptionsItemSelected(MenuItem item) {
if (item.getItemId() == android.R.id.home) {
finish();
} else if (item.getItemId() == R.id.menu_refresh) {
//mRecyclerView.forceToRefresh();
mDataAdapter.remove(mLRecyclerViewAdapter.getAdapterPosition(false,3));
mRecyclerView.forceToRefresh();
//mDataAdapter.remove(mLRecyclerViewAdapter.getAdapterPosition(false,3));
}
return true;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -154,7 +154,7 @@ public void onScrollStateChanged(int state) {

});

onRefresh();
//onRefresh();
}

@Override
Expand Down

0 comments on commit 2ab0df0

Please sign in to comment.