Code example for ActionBar

Methods: hide, setNavigationMode

0
    void resume() { 
        AbstractGalleryActivity activity = mActivity;
        ActionBar actionBar = activity.getActionBar();
        if (actionBar != null) {
            if ((mFlags & FLAG_HIDE_ACTION_BAR) != 0) {
                actionBar.hide();
            } else { 
                actionBar.show();
            } 
            int stateCount = mActivity.getStateManager().getStateCount();
            mActivity.getGalleryActionBar().setDisplayOptions(stateCount > 1, true);
            // Default behavior, this can be overridden in ActivityState's onResume. 
            actionBar.setNavigationMode(ActionBar.NAVIGATION_MODE_STANDARD);
        } 
 
        activity.invalidateOptionsMenu();
 
        setScreenFlags(); 
 
        boolean lightsOut = ((mFlags & FLAG_HIDE_STATUS_BAR) != 0);
        mActivity.getGLRoot().setLightsOutMode(lightsOut);