Reputation: 125
there are launcher which offers the possibility to hide or protect the status bar. i tried to get the position of the menu with TouchEvent and menu position when there is a touch I put a popup to say you are not allowed but the touchEvent gives actions on screen so how can I hide the status bar I tried
getWindow().setFlags(WindowManager.LayoutParams.FLAG_FULLSCREEN,WindowManager.LayoutParams.FLAG_FULLSCREEN);
setContentView(R.layout.main_grid);
mGrid = (GridView) findViewById(R.id.gridview);
mGrid.setColumnWidth(95);
mGrid.setVisibility(0x00000000);
mGrid.setSystemUiVisibility(View.SYSTEM_UI_FLAG_LAYOUT_HIDE_NAVIGATION);
Upvotes: 1
Views: 3331
Reputation: 1944
Did you try this in your Manifest?
android:theme="@android:style/Theme.NoTitleBar.Fullscreen"
Upvotes: 0
Reputation: 14183
you can do it programmatically by calling
getWindow().setFlags(WindowManager.LayoutParams.FLAG_FULLSCREEN,WindowManager.LayoutParams.FLAG_FULLSCREEN);
I think you must do it before than
setContentView(whatever);
or by editing app style, adding
<item name="android:windowFullscreen">true</item>
inside <style>
Upvotes: 2