Loading services/core/java/com/android/server/policy/PhoneWindowManager.java +5 −1 Original line number Diff line number Diff line Loading @@ -2270,7 +2270,11 @@ public class PhoneWindowManager implements WindowManagerPolicy { // Only force the default orientation if the screen is xlarge, at least 960dp x 720dp, per // http://developer.android.com/guide/practices/screens_support.html#range mForceDefaultOrientation = longSizeDp >= 960 && shortSizeDp >= 720 && // For car, ignore the dp limitation. It's physically impossible to rotate the car's screen // so if the orientation is forced, we need to respect that no matter what. boolean isCar = mContext.getPackageManager().hasSystemFeature( PackageManager.FEATURE_AUTOMOTIVE); mForceDefaultOrientation = ((longSizeDp >= 960 && shortSizeDp >= 720) || isCar) && res.getBoolean(com.android.internal.R.bool.config_forceDefaultOrientation) && // For debug purposes the next line turns this feature off with: // $ adb shell setprop config.override_forced_orient true Loading Loading
services/core/java/com/android/server/policy/PhoneWindowManager.java +5 −1 Original line number Diff line number Diff line Loading @@ -2270,7 +2270,11 @@ public class PhoneWindowManager implements WindowManagerPolicy { // Only force the default orientation if the screen is xlarge, at least 960dp x 720dp, per // http://developer.android.com/guide/practices/screens_support.html#range mForceDefaultOrientation = longSizeDp >= 960 && shortSizeDp >= 720 && // For car, ignore the dp limitation. It's physically impossible to rotate the car's screen // so if the orientation is forced, we need to respect that no matter what. boolean isCar = mContext.getPackageManager().hasSystemFeature( PackageManager.FEATURE_AUTOMOTIVE); mForceDefaultOrientation = ((longSizeDp >= 960 && shortSizeDp >= 720) || isCar) && res.getBoolean(com.android.internal.R.bool.config_forceDefaultOrientation) && // For debug purposes the next line turns this feature off with: // $ adb shell setprop config.override_forced_orient true Loading