Code example for Fragment

Methods: onDestroyView

    public void onDestroyView() { 
        mList = null;
     * This method will be called when an item in the list is selected. 
     * Subclasses should override. Subclasses can call 
     * getListView().getItemAtPosition(position) if they need to access the 
     * data associated with the selected item. 
     * @param l The ListView where the click happened 
     * @param v The view that was clicked within the ListView 
     * @param position The position of the view in the list 
     * @param id The row id of the item that was clicked 
    public void onListItemClick(ListView l, View v, int position, long id) {