summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--core/res/res/values/config.xml4
-rw-r--r--core/res/res/values/symbols.xml1
-rw-r--r--packages/SettingsLib/src/com/android/settingslib/wifi/AccessPoint.java2
-rw-r--r--packages/SettingsProvider/res/values/defaults.xml2
-rw-r--r--packages/SettingsProvider/src/com/android/providers/settings/SettingsProvider.java15
-rw-r--r--packages/overlays/NavigationBarModeGesturalOverlay/res/values/config.xml4
-rw-r--r--services/core/java/com/android/server/wm/DisplayPolicy.java8
7 files changed, 31 insertions, 5 deletions
diff --git a/core/res/res/values/config.xml b/core/res/res/values/config.xml
index 5c593ca1fea5..0daebd76daf4 100644
--- a/core/res/res/values/config.xml
+++ b/core/res/res/values/config.xml
@@ -3302,6 +3302,10 @@
{@link Window#setEnsuringNavigationBarContrastWhenTransparent}. -->
<bool name="config_navBarNeedsScrim">true</bool>
+ <!-- Controls whether seamless rotation should be allowed even though the navbar can move
+ (which normally prevents seamless rotation). -->
+ <bool name="config_allowSeamlessRotationDespiteNavBarMoving">false</bool>
+
<!-- Default insets [LEFT/RIGHTxTOP/BOTTOM] from the screen edge for picture-in-picture windows.
These values are in DPs and will be converted to pixel sizes internally. -->
<string translatable="false" name="config_defaultPictureInPictureScreenEdgeInsets">16x16</string>
diff --git a/core/res/res/values/symbols.xml b/core/res/res/values/symbols.xml
index a00a294b535f..1ef2eb4a0435 100644
--- a/core/res/res/values/symbols.xml
+++ b/core/res/res/values/symbols.xml
@@ -2875,6 +2875,7 @@
<java-symbol type="bool" name="config_navBarTapThrough" />
<java-symbol type="bool" name="config_navBarAlwaysShowOnSideEdgeGesture" />
<java-symbol type="bool" name="config_navBarNeedsScrim" />
+ <java-symbol type="bool" name="config_allowSeamlessRotationDespiteNavBarMoving" />
<java-symbol type="dimen" name="config_backGestureInset" />
<java-symbol type="color" name="system_bar_background_semi_transparent" />
diff --git a/packages/SettingsLib/src/com/android/settingslib/wifi/AccessPoint.java b/packages/SettingsLib/src/com/android/settingslib/wifi/AccessPoint.java
index 4d332b9a95b4..05af4e1f80b3 100644
--- a/packages/SettingsLib/src/com/android/settingslib/wifi/AccessPoint.java
+++ b/packages/SettingsLib/src/com/android/settingslib/wifi/AccessPoint.java
@@ -1240,7 +1240,7 @@ public class AccessPoint implements Comparable<AccessPoint> {
// Special handling for PSK-SAE transition mode. If the AP has advertised both,
// we compare the key with both PSK and SAE for a match.
return TextUtils.equals(mKey.substring(0, mKey.lastIndexOf(',')),
- compareTo.substring(0, mKey.lastIndexOf(',')));
+ compareTo.substring(0, compareTo.lastIndexOf(',')));
}
}
return mKey.equals(compareTo);
diff --git a/packages/SettingsProvider/res/values/defaults.xml b/packages/SettingsProvider/res/values/defaults.xml
index 715e1ebe31ac..dd72d5779c19 100644
--- a/packages/SettingsProvider/res/values/defaults.xml
+++ b/packages/SettingsProvider/res/values/defaults.xml
@@ -225,7 +225,7 @@
<bool name="def_charging_sounds_enabled">true</bool>
<!-- Default for Settings.Secure.NOTIFICATION_BUBBLES -->
- <bool name="def_notification_bubbles">true</bool>
+ <bool name="def_notification_bubbles">false</bool>
<!-- Default for Settings.Secure.AWARE_ENABLED -->
<bool name="def_aware_enabled">false</bool>
diff --git a/packages/SettingsProvider/src/com/android/providers/settings/SettingsProvider.java b/packages/SettingsProvider/src/com/android/providers/settings/SettingsProvider.java
index 82592ceeb710..6558c87aaf3a 100644
--- a/packages/SettingsProvider/src/com/android/providers/settings/SettingsProvider.java
+++ b/packages/SettingsProvider/src/com/android/providers/settings/SettingsProvider.java
@@ -3237,7 +3237,7 @@ public class SettingsProvider extends ContentProvider {
}
private final class UpgradeController {
- private static final int SETTINGS_VERSION = 179;
+ private static final int SETTINGS_VERSION = 180;
private final int mUserId;
@@ -4387,6 +4387,19 @@ public class SettingsProvider extends ContentProvider {
currentVersion = 179;
}
+ if (currentVersion == 179) {
+ // Version 178: Reset the default for Secure Settings: NOTIFICATION_BUBBLES
+ // This is originally set in version 173, however, the default value changed
+ // so this step is to ensure the value is updated to the correct defaulte
+ final SettingsState secureSettings = getSecureSettingsLocked(userId);
+
+ secureSettings.insertSettingLocked(Secure.NOTIFICATION_BUBBLES,
+ getContext().getResources().getBoolean(
+ R.bool.def_notification_bubbles) ? "1" : "0", null,
+ true, SettingsState.SYSTEM_PACKAGE_NAME);
+
+ currentVersion = 180;
+ }
// vXXX: Add new settings above this point.
diff --git a/packages/overlays/NavigationBarModeGesturalOverlay/res/values/config.xml b/packages/overlays/NavigationBarModeGesturalOverlay/res/values/config.xml
index 9694e76e138b..f1d2e0b27353 100644
--- a/packages/overlays/NavigationBarModeGesturalOverlay/res/values/config.xml
+++ b/packages/overlays/NavigationBarModeGesturalOverlay/res/values/config.xml
@@ -37,6 +37,10 @@
{@link Window#setEnsuringNavigationBarContrastWhenTransparent}. -->
<bool name="config_navBarNeedsScrim">false</bool>
+ <!-- Controls whether seamless rotation should be allowed even though the navbar can move
+ (which normally prevents seamless rotation). -->
+ <bool name="config_allowSeamlessRotationDespiteNavBarMoving">true</bool>
+
<!-- Controls whether the side edge gestures can always trigger the transient nav bar to
show. -->
<bool name="config_navBarAlwaysShowOnSideEdgeGesture">true</bool>
diff --git a/services/core/java/com/android/server/wm/DisplayPolicy.java b/services/core/java/com/android/server/wm/DisplayPolicy.java
index b8504db8e810..197a3cf2b3ab 100644
--- a/services/core/java/com/android/server/wm/DisplayPolicy.java
+++ b/services/core/java/com/android/server/wm/DisplayPolicy.java
@@ -255,6 +255,7 @@ public class DisplayPolicy {
private volatile boolean mNavigationBarCanMove;
private volatile boolean mNavigationBarLetsThroughTaps;
private volatile boolean mNavigationBarAlwaysShowOnSideGesture;
+ private volatile boolean mAllowSeamlessRotationDespiteNavBarMoving;
// Written by vr manager thread, only read in this class.
private volatile boolean mPersistentVrModeEnabled;
@@ -2726,6 +2727,8 @@ public class DisplayPolicy {
mNavigationBarCanMove =
mDisplayContent.mBaseDisplayWidth != mDisplayContent.mBaseDisplayHeight
&& res.getBoolean(R.bool.config_navBarCanMove);
+ mAllowSeamlessRotationDespiteNavBarMoving =
+ res.getBoolean(R.bool.config_allowSeamlessRotationDespiteNavBarMoving);
}
/**
@@ -3508,8 +3511,9 @@ public class DisplayPolicy {
}
// If the navigation bar can't change sides, then it will
// jump when we change orientations and we don't rotate
- // seamlessly.
- if (!navigationBarCanMove()) {
+ // seamlessly - unless that is allowed, eg. with gesture
+ // navigation where the navbar is low-profile enough that this isn't very noticeable.
+ if (!navigationBarCanMove() && !mAllowSeamlessRotationDespiteNavBarMoving) {
return false;
}