Java tutorial
//package com.java2s; import android.annotation.TargetApi; import android.app.Activity; import android.os.Build.VERSION_CODES; import android.view.View; public class Main { @TargetApi(VERSION_CODES.KITKAT) public static void showSystemUI(Activity activity) { View decorView = activity.getWindow().getDecorView(); decorView.setSystemUiVisibility(View.SYSTEM_UI_FLAG_LAYOUT_STABLE | View.SYSTEM_UI_FLAG_LAYOUT_HIDE_NAVIGATION | View.SYSTEM_UI_FLAG_LAYOUT_FULLSCREEN); } }