@Override public void setupDisplay() { uiFlags = View.SYSTEM_UI_FLAG_LOW_PROFILE; if (!onScreenInput) { uiFlags |= View.SYSTEM_UI_FLAG_LAYOUT_HIDE_NAVIGATION | View.SYSTEM_UI_FLAG_LAYOUT_FULLSCREEN; if (uiFullscreen) { uiFlags |= View.SYSTEM_UI_FLAG_FULLSCREEN | View.SYSTEM_UI_FLAG_HIDE_NAVIGATION; } } else { super.setActionBarState(); } super.setupDisplay(); }
@Override public void screenTouched(MotionEvent aEvent) { super.screenTouched(aEvent); if (toggleFullscreenOverActionBar(aEvent.getY())) { setupDisplay(); } }
@Override public void screenTouched(MotionEvent aEvent) { super.screenTouched(aEvent); if (!onScreenInput) { if (!touchedOverActionBar(aEvent.getY())) { uiFullscreen = true; setupDisplay(); } } else if (toggleFullscreenOverActionBar(aEvent.getY())) { setupDisplay(); } }
@Override public void windowCreated() { super.windowCreated(); activity.view.setOnSystemUiVisibilityChangeListener( new View.OnSystemUiVisibilityChangeListener() { @Override public void onSystemUiVisibilityChange(int aVisibility) { if (!onScreenInput) { uiFullscreen = (aVisibility & View.SYSTEM_UI_FLAG_HIDE_NAVIGATION) != 0; } } }); }
@Override public void setupDisplay() { super.setupDisplay(); super.setActionBarState(); }