コード例 #1
0
 @Override
 public void onLoadFinished(Loader<Cursor> cursorLoader, Cursor cursor) {
   mArtistCursorAdapter.swapCursor(cursor);
   if (mPosition != ListView.INVALID_POSITION) {
     // If we don't need to restart the loader, and there's a desired position to restore
     // to, do so now.
     mListView.smoothScrollToPosition(mPosition);
   }
 }
コード例 #2
0
 @Override
 public void onLoaderReset(Loader<Cursor> loader) {
   mArtistCursorAdapter.swapCursor(null);
 }