List of usage examples for android.content.res Configuration NAVIGATIONHIDDEN_YES
int NAVIGATIONHIDDEN_YES
To view the source code for android.content.res Configuration NAVIGATIONHIDDEN_YES.
Click Source Link
From source file:com.vuze.android.remote.AndroidUtils.java
public static boolean usesNavigationControl() { Configuration configuration = VuzeRemoteApp.getContext().getResources().getConfiguration(); if (configuration.navigation == Configuration.NAVIGATION_NONAV) { return false; } else if (configuration.touchscreen == Configuration.TOUCHSCREEN_FINGER) { return false; } else if (configuration.navigation == Configuration.NAVIGATION_DPAD) { return true; } else if (configuration.touchscreen == Configuration.TOUCHSCREEN_NOTOUCH) { return true; } else if (configuration.touchscreen == Configuration.TOUCHSCREEN_UNDEFINED) { return true; } else if (configuration.navigationHidden == Configuration.NAVIGATIONHIDDEN_YES) { return true; } else if (configuration.uiMode == Configuration.UI_MODE_TYPE_TELEVISION) { return true; }/*from w w w . ja va 2s. c om*/ return false; }
From source file:com.miz.functions.MizLib.java
/** * Determines if the device uses navigation controls as the primary navigation from a number of factors. * @param context Application Context/*from w w w . ja va 2 s. c om*/ * @return True if the device uses navigation controls, false otherwise. */ public static boolean usesNavigationControl(Context context) { Configuration configuration = context.getResources().getConfiguration(); if (configuration.navigation == Configuration.NAVIGATION_NONAV) { return false; } else if (configuration.touchscreen == Configuration.TOUCHSCREEN_FINGER) { return false; } else if (configuration.navigation == Configuration.NAVIGATION_DPAD) { return true; } else if (configuration.touchscreen == Configuration.TOUCHSCREEN_NOTOUCH) { return true; } else if (configuration.touchscreen == Configuration.TOUCHSCREEN_UNDEFINED) { return true; } else if (configuration.navigationHidden == Configuration.NAVIGATIONHIDDEN_YES) { return true; } else if (configuration.uiMode == Configuration.UI_MODE_TYPE_TELEVISION) { return true; } return false; }