Merge "Swap cursor in adapter, don't remake adapter."
diff --git a/src/com/android/mail/ui/ConversationListFragment.java b/src/com/android/mail/ui/ConversationListFragment.java
index 3f27db6..8ada1f2 100644
--- a/src/com/android/mail/ui/ConversationListFragment.java
+++ b/src/com/android/mail/ui/ConversationListFragment.java
@@ -201,6 +201,10 @@
         }
         mActivity = (ControllableActivity) activity;
         mCallbacks = mActivity.getListHandler();
+
+        mListAdapter = new AnimatedAdapter(mActivity.getApplicationContext(), -1,
+                mConversationListCursor, mSelectedSet, mAccount);
+        mListView.setAdapter(mListAdapter);
         // Don't need to add ourselves to our own set observer.
         // mActivity.getBatchConversations().addObserver(this);
         mActivity.setViewModeListener(this);
@@ -283,7 +287,6 @@
 
         // Note - we manually save/restore the listview state.
         mListView.setSaveEnabled(false);
-
         return rootView;
     }
 
@@ -494,13 +497,8 @@
 
     @Override
     public void onLoadFinished(Loader<ConversationCursor> loader, ConversationCursor data) {
-        // TODO: (mindyp) use real selected position.
-        int position = 0;
         mConversationListCursor = data;
-        // TODO(viki): The AnimatedAdapter shouldn't pass the selected set around like this.
-        mListAdapter = new AnimatedAdapter(mActivity.getApplicationContext(), position,
-                mConversationListCursor, mSelectedSet, mAccount);
-        mListView.setAdapter(mListAdapter);
+        mListAdapter.swapCursor(mConversationListCursor);
         mConversationListCursor.addListener(this);
         configureSearchResultHeader();
     }