试图实现LoaderManager + CursorLoader.
在onFinish方法适配器应交换其光标
public void onLoadFinished(Loader<Cursor> loader, Cursor data) {
// Swap the new cursor in. (The framework will take care of closing the
// old cursor once we return.)
mAdapter.swapCursor(data);
}
Run Code Online (Sandbox Code Playgroud)
但是,自API级别11以来,swapCursor可用.
那么我应该如何在android API 10中交换光标呢?
| 归档时间: |
|
| 查看次数: |
2511 次 |
| 最近记录: |