Code example for ListFragment

Methods: getActivity, getListView, getView

0
    /** 
     * Handle {@link SessionsQuery} {@link Cursor}. 
     */ 
    private void onSessionOrSearchQueryComplete(Cursor cursor) {
        mCursor = cursor;
        getActivity().startManagingCursor(mCursor);
        mAdapter.changeCursor(mCursor);
        if (mCheckedPosition >= 0 && getView() != null) {
            getListView().setItemChecked(mCheckedPosition, true);
        } 
    } 
 
    /** 
     * Handle {@link TracksQuery} {@link Cursor}. 
     */ 
    private void onTrackQueryComplete(Cursor cursor) {
        try { 
            if (!cursor.moveToFirst()) {
                return; 
            }