Skip to content

Commit

Permalink
Further fixes for PR #85 - bugs in setAdapter
Browse files Browse the repository at this point in the history
  • Loading branch information
denizmveli committed Apr 6, 2014
1 parent 18e9ae8 commit 2fce475
Showing 1 changed file with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -267,9 +267,9 @@ public void setAdapter(final ListAdapter adapter) {
mDataChanged = true;
mItemCount = mAdapter != null ? mAdapter.getCount() : 0;

if (adapter != null) {
adapter.registerDataSetObserver(mObserver);
mRecycleBin.setViewTypeCount(adapter.getViewTypeCount());
if (mAdapter != null) {
mAdapter.registerDataSetObserver(mObserver);
mRecycleBin.setViewTypeCount(mAdapter.getViewTypeCount());
}

requestLayout();
Expand Down

1 comment on commit 2fce475

@chetanprajapat
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

thank u very much ..........

Please sign in to comment.