hide the navigation bar icons if they are software ones
This commit is contained in:
parent
ddf942062f
commit
b7b5f8e8e8
|
@ -36,6 +36,7 @@ public class MainActivity extends AppCompatActivity {
|
||||||
preview = new Preview(this, (SurfaceView) findViewById(R.id.surfaceView));
|
preview = new Preview(this, (SurfaceView) findViewById(R.id.surfaceView));
|
||||||
preview.setLayoutParams(new ViewGroup.LayoutParams(ViewGroup.LayoutParams.MATCH_PARENT, ViewGroup.LayoutParams.MATCH_PARENT));
|
preview.setLayoutParams(new ViewGroup.LayoutParams(ViewGroup.LayoutParams.MATCH_PARENT, ViewGroup.LayoutParams.MATCH_PARENT));
|
||||||
viewHolder.addView(preview);
|
viewHolder.addView(preview);
|
||||||
|
hideNavigationBarIcons();
|
||||||
}
|
}
|
||||||
|
|
||||||
@OnClick(R.id.toggle_camera)
|
@OnClick(R.id.toggle_camera)
|
||||||
|
@ -74,6 +75,10 @@ public class MainActivity extends AppCompatActivity {
|
||||||
preview.takePicture();
|
preview.takePicture();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private void hideNavigationBarIcons() {
|
||||||
|
getWindow().getDecorView().setSystemUiVisibility(View.SYSTEM_UI_FLAG_LOW_PROFILE);
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
protected void onResume() {
|
protected void onResume() {
|
||||||
super.onResume();
|
super.onResume();
|
||||||
|
|
Loading…
Reference in New Issue