As you can see by the picture the navigationbar and the statusbar is overlaying the layout. All I have done is
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.KITKAT) {
Window w = getWindow();
w.setFlags(WindowManager.LayoutParams.FLAG_TRANSLUCENT_NAVIGATION, WindowManager.LayoutParams.FLAG_TRANSLUCENT_NAVIGATION);
w.setFlags(WindowManager.LayoutParams.FLAG_TRANSLUCENT_STATUS, WindowManager.LayoutParams.FLAG_TRANSLUCENT_STATUS); w.setFlags(WindowManager.LayoutParams.FLAG_FORCE_NOT_FULLSCREEN,WindowManager.LayoutParams.FLAG_FORCE_NOT_FULLSCREEN);
}
I have tried to disable the overlay by doing :
w.clearFlags(View.SYSTEM_UI_FLAG_LAYOUT_STABLE);
w.clearFlags(View.SYSTEM_UI_FLAG_FULLSCREEN);
w.setFlags(WindowManager.LayoutParams.FLAG_FORCE_NOT_FULLSCREEN,WindowManager.LayoutParams.FLAG_FORCE_NOT_FULLSCREEN);
but with no success. Help is appreciated with a 1up
Thank you
I believe you're trying to put your application in Immersive Mode. If so, this is the code I found from Google,which will put your app in immersive mode and on touch will show the Status bar and Navigation Bar.
Are you using a custom theme that does this? Such a setting
android:windowActionBarOverlay
to true?If so, disable that in the theme.
Source: http://developer.android.com/training/basics/actionbar/overlaying.html