diff options
| author | 2018-01-16 16:37:22 +0000 | |
|---|---|---|
| committer | 2018-01-17 18:04:04 +0000 | |
| commit | 9669e90c8dbb38e27774f5f897893a43ce3300ca (patch) | |
| tree | 36639aa597ce105981e1a217c4cdba91aa13c7f7 | |
| parent | 52c3685613554319651df6db00162f575ce38e4e (diff) | |
Create Settings.Global.ENABLE_SMART_REPLIES_IN_NOTIFICATIONS setting
This will allow us to toggle and experiment with the feature.
Bug: 67765414
Test: atest SettingsBackupTest
Change-Id: I28d0a817561cb6811966d229e8367adb4eb6d40b
4 files changed, 13 insertions, 1 deletions
diff --git a/core/java/android/provider/Settings.java b/core/java/android/provider/Settings.java index 6d91f59b2727..e380a6a7d4e0 100644 --- a/core/java/android/provider/Settings.java +++ b/core/java/android/provider/Settings.java @@ -11300,6 +11300,13 @@ public final class Settings { */ public static final String ZRAM_ENABLED = "zram_enabled"; + + /** + * Whether smart replies in notifications are enabled. + * @hide + */ + public static final String ENABLE_SMART_REPLIES_IN_NOTIFICATIONS = + "enable_smart_replies_in_notifications"; } /** diff --git a/core/proto/android/providers/settings.proto b/core/proto/android/providers/settings.proto index d4bdb9b577dc..3ffb254b2333 100644 --- a/core/proto/android/providers/settings.proto +++ b/core/proto/android/providers/settings.proto @@ -389,8 +389,9 @@ message GlobalSettingsProto { optional SettingProto notification_snooze_options = 341; optional SettingProto enable_gnss_raw_meas_full_tracking = 346; optional SettingProto zram_enabled = 347; + optional SettingProto enable_smart_replies_in_notifications = 348; - // Next tag = 348; + // Next tag = 349; } message SecureSettingsProto { diff --git a/core/tests/coretests/src/android/provider/SettingsBackupTest.java b/core/tests/coretests/src/android/provider/SettingsBackupTest.java index 410bee025df4..c29d79c59dc9 100644 --- a/core/tests/coretests/src/android/provider/SettingsBackupTest.java +++ b/core/tests/coretests/src/android/provider/SettingsBackupTest.java @@ -204,6 +204,7 @@ public class SettingsBackupTest { Settings.Global.ENABLE_DELETION_HELPER_NO_THRESHOLD_TOGGLE, Settings.Global.ENABLE_DISKSTATS_LOGGING, Settings.Global.ENABLE_EPHEMERAL_FEATURE, + Settings.Global.ENABLE_SMART_REPLIES_IN_NOTIFICATIONS, Settings.Global.ENHANCED_4G_MODE_ENABLED, Settings.Global.EPHEMERAL_COOKIE_MAX_SIZE_BYTES, Settings.Global.ERROR_LOGCAT_PREFIX, diff --git a/packages/SettingsProvider/src/com/android/providers/settings/SettingsProtoDumpUtil.java b/packages/SettingsProvider/src/com/android/providers/settings/SettingsProtoDumpUtil.java index 36981320ba5f..d33e0841a906 100644 --- a/packages/SettingsProvider/src/com/android/providers/settings/SettingsProtoDumpUtil.java +++ b/packages/SettingsProvider/src/com/android/providers/settings/SettingsProtoDumpUtil.java @@ -1122,6 +1122,9 @@ class SettingsProtoDumpUtil { dumpSetting(s, p, Settings.Global.ZRAM_ENABLED, GlobalSettingsProto.ZRAM_ENABLED); + dumpSetting(s, p, + Settings.Global.ENABLE_SMART_REPLIES_IN_NOTIFICATIONS, + GlobalSettingsProto.ENABLE_SMART_REPLIES_IN_NOTIFICATIONS); } /** Dump a single {@link SettingsState.Setting} to a proto buf */ |