Java Code Examples for android.view.View#getWindowSystemUiVisibility()

The following examples show how to use android.view.View#getWindowSystemUiVisibility() . These examples are extracted from open source projects. You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may want to check out the right sidebar which shows the related API usage.
Example 1
Source Project: UTubeTV   File: DUtils.java    License: The Unlicense 5 votes vote down vote up
public static String systemUIVisibilityString(View theView) {
  int crap = theView.getWindowSystemUiVisibility();

  int duhs[] = {View.SYSTEM_UI_FLAG_LOW_PROFILE, View.SYSTEM_UI_FLAG_HIDE_NAVIGATION, View.SYSTEM_UI_FLAG_FULLSCREEN, View.SYSTEM_UI_FLAG_LAYOUT_STABLE, View.SYSTEM_UI_FLAG_LAYOUT_HIDE_NAVIGATION, View.SYSTEM_UI_FLAG_LAYOUT_FULLSCREEN, View.SYSTEM_UI_FLAG_IMMERSIVE, View.SYSTEM_UI_FLAG_IMMERSIVE_STICKY};
  String result = "OK: 0";

  for (int duh : duhs) {
    if ((crap & duh) == duh) {
      switch (duh) {
        case View.SYSTEM_UI_FLAG_LOW_PROFILE:
          result += " | SYSTEM_UI_FLAG_LOW_PROFILE";
          break;
        case View.SYSTEM_UI_FLAG_HIDE_NAVIGATION:
          result += " | SYSTEM_UI_FLAG_HIDE_NAVIGATION";
          break;
        case View.SYSTEM_UI_FLAG_FULLSCREEN:
          result += " | SYSTEM_UI_FLAG_FULLSCREEN";
          break;
        case View.SYSTEM_UI_FLAG_LAYOUT_STABLE:
          result += " | SYSTEM_UI_FLAG_LAYOUT_STABLE";
          break;
        case View.SYSTEM_UI_FLAG_LAYOUT_HIDE_NAVIGATION:
          result += " | SYSTEM_UI_FLAG_LAYOUT_HIDE_NAVIGATION";
          break;
        case View.SYSTEM_UI_FLAG_LAYOUT_FULLSCREEN:
          result += " | SYSTEM_UI_FLAG_LAYOUT_FULLSCREEN";
          break;
        case View.SYSTEM_UI_FLAG_IMMERSIVE:
          result += " | SYSTEM_UI_FLAG_IMMERSIVE";
          break;
        case View.SYSTEM_UI_FLAG_IMMERSIVE_STICKY:
          result += " | SYSTEM_UI_FLAG_IMMERSIVE_STICKY";
          break;
      }
    }
  }

  return result;
}
 
Example 2
Source Project: letv   File: ViewCompatJellybeanMr1.java    License: Apache License 2.0 4 votes vote down vote up
public static int getWindowSystemUiVisibility(View view) {
    return view.getWindowSystemUiVisibility();
}
 
Example 3
public static int getWindowSystemUiVisibility(View view) {
    return view.getWindowSystemUiVisibility();
}