Code example for ActionBar

Methods: getSelectedNavigationIndex

0
    } 
 
    @Override 
    protected void onSaveInstanceState(Bundle outState) {
        super.onSaveInstanceState(outState);
        outState.putInt(STATE_NAVIGATION_INDEX, bar.getSelectedNavigationIndex());
        outState.putString(STATE_SUBREDDIT, subreddit);
    } 
 
    private ThingListFragment getThingListFragment() { 
        return (ThingListFragment) getFragmentManager().findFragmentByTag(ThingListFragment.TAG); 
    } 
} 
Stop searching for code, let great code find you!  Add Codota to your java IDE