我有这个场景
onResume of a activity:
@Override
protected void onResume() {
if (adapter1!=null) adapter1.notifyDataSetChanged();
if (adapter2!=null) adapter2.notifyDataSetChanged();
if (adapter3!=null) adapter3.notifyDataSetChanged();
super.onResume();
}
适配器已被定义为:
public class ListCursorAdapter extends SimpleCursorAdapter {
Cursor c;
/* (non-Javadoc)
* @see android.widget.CursorAdapter#onContentChanged()
*/
@Override
protected void onContentChanged() {
// this is not called
if (c!=null) c.requery();
super.onContentChanged();
}
}
虽然onResume和对适配器的调用已发出,但未触发onContentChanged事件。有什么问题?