From 59be362d670cdecad11723202c873b9e74483f51 Mon Sep 17 00:00:00 2001 From: Abhijeet Kaur Date: Tue, 30 Jul 2019 15:53:56 +0100 Subject: [PATCH] Use USE_BUGREPORT_API flag from FeatureFlagUtils To avoid flag duplication, this flag is moved to FeatureFlagUtils.java where other callers can also use this flag. Using this flag's value from FeatureFlagUtils instead of the local FeatureFlag file in Settings. Bug: 136548292 Test: Settings can still access this feature flag as before Test: Builds and API workflow gets triggered by turning on the flag Change-Id: I60e4d96033219c934a43e728705fee93e338d60e --- src/com/android/settings/BugreportPreference.java | 4 ++-- src/com/android/settings/core/FeatureFlags.java | 1 - 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/src/com/android/settings/BugreportPreference.java b/src/com/android/settings/BugreportPreference.java index f5b739a84e5..ee551c180da 100644 --- a/src/com/android/settings/BugreportPreference.java +++ b/src/com/android/settings/BugreportPreference.java @@ -114,8 +114,8 @@ public class BugreportPreference extends CustomDialogPreferenceCompat { // untouched. To switch to the new workflow using Bugreport API run the following // commands on the terminal: // * adb root - // * adb shell setprop settings_call_bugreport_api true - if (FeatureFlagUtils.isEnabled(context, FeatureFlags.USE_BUGREPORT_API)) { + // * adb shell setprop settings_use_bugreport_api true + if (FeatureFlagUtils.isEnabled(context, FeatureFlagUtils.USE_BUGREPORT_API)) { Intent triggerShellBugreport = new Intent(); triggerShellBugreport.setAction(INTENT_BUGREPORT_REQUESTED); triggerShellBugreport.setPackage(SHELL_APP_PACKAGE); diff --git a/src/com/android/settings/core/FeatureFlags.java b/src/com/android/settings/core/FeatureFlags.java index b13d712c8c8..fee9c42a82d 100644 --- a/src/com/android/settings/core/FeatureFlags.java +++ b/src/com/android/settings/core/FeatureFlags.java @@ -21,7 +21,6 @@ package com.android.settings.core; */ public class FeatureFlags { public static final String AUDIO_SWITCHER_SETTINGS = "settings_audio_switcher"; - public static final String USE_BUGREPORT_API = "settings_call_bugreport_api"; public static final String DYNAMIC_SYSTEM = "settings_dynamic_system"; public static final String HEARING_AID_SETTINGS = "settings_bluetooth_hearing_aid"; public static final String MOBILE_NETWORK_V2 = "settings_mobile_network_v2";