Code example for CursorAdapter

Methods: getCursor

0
 
    /** 
     * {@inheritDoc} 
     */ 
    public void onItemSelected(AdapterView<?> parent, View view, int position, long id) {
        mImageLoader.preload(getCursor(), COLUMN_ALBUM_IMAGE, position - 5, position + 5);
    } 
 
    /** 
     * {@inheritDoc} 
     */ 
    public void onNothingSelected(AdapterView<?> parent) {
    } 
 
    @Override 
    public void notifyDataSetChanged() { 
        super.notifyDataSetChanged(); 
 
        // Pre-fetch album covers 
        Cursor cursor = getCursor();
        mImageLoader.prefetch(cursor, COLUMN_ALBUM_IMAGE);