Code example for ListFragment

Methods: getListView, onActivityCreated, registerForContextMenu

0
        return view;
    } 
 
    @Override 
    public void onActivityCreated(Bundle savedInstanceState) {
        super.onActivityCreated(savedInstanceState);
        registerForContextMenu(getListView());
    } 
 
    @Override 
    public void onResume() { 
        super.onResume(); 
    } 
 
    public void initFragment(View v) {
        mListView = (ListView) v.findViewById(android.R.id.list);
        mPlatoonUserListAdapter = new PlatoonUserListAdapter(null, mLayoutInflater);
        mListView.setAdapter(mPlatoonUserListAdapter);
         
        mViewingMembers = true;
Stop searching for code, let great code find you!  Add Codota to your java IDE