Cleanup ENABLE_GESTURE_ERROR_DETECTION

Flag: ENABLE_GESTURE_ERROR_DETECTION
Fixes: 270389990
Test: printed gesture nav logs
Change-Id: I68317b75b10d46ccae29206d94290e013b2a7cca
This commit is contained in:
Schneider Victor-tulias
2023-04-05 15:15:20 -07:00
parent acb218294b
commit 6fca4b795b
3 changed files with 7 additions and 15 deletions
@@ -86,9 +86,7 @@ public class MultiStateCallback {
Log.d(TAG, "[" + System.identityHashCode(this) + "] Adding "
+ convertToFlagNames(stateFlag) + " to " + convertToFlagNames(mState));
}
if (FeatureFlags.ENABLE_GESTURE_ERROR_DETECTION.get()) {
trackGestureEvents(stateFlag);
}
trackGestureEvents(stateFlag);
final int oldState = mState;
mState = mState | stateFlag;
@@ -155,15 +155,13 @@ public class ActiveGestureLog {
}
public void dump(String prefix, PrintWriter writer) {
if (FeatureFlags.ENABLE_GESTURE_ERROR_DETECTION.get()) {
writer.println(prefix + "ActiveGestureErrorDetector:");
for (int i = 0; i < logs.length; i++) {
EventLog eventLog = logs[(nextIndex + i) % logs.length];
if (eventLog == null) {
continue;
}
ActiveGestureErrorDetector.analyseAndDump(prefix + '\t', writer, eventLog);
writer.println(prefix + "ActiveGestureErrorDetector:");
for (int i = 0; i < logs.length; i++) {
EventLog eventLog = logs[(nextIndex + i) % logs.length];
if (eventLog == null) {
continue;
}
ActiveGestureErrorDetector.analyseAndDump(prefix + '\t', writer, eventLog);
}
writer.println(prefix + "ActiveGestureLog history:");
@@ -76,10 +76,6 @@ public final class FeatureFlags {
* Declare a new ToggleableFlag below. Give it a unique key (e.g. "QSB_ON_FIRST_SCREEN"),
* and set a default value for the flag. This will be the default value on Debug builds.
*/
public static final BooleanFlag ENABLE_GESTURE_ERROR_DETECTION = getDebugFlag(270389990,
"ENABLE_GESTURE_ERROR_DETECTION", ENABLED,
"Analyze gesture events and log detected errors");
// When enabled the promise icon is visible in all apps while installation an app.
public static final BooleanFlag PROMISE_APPS_IN_ALL_APPS = getDebugFlag(270390012,
"PROMISE_APPS_IN_ALL_APPS", DISABLED, "Add promise icon in all-apps");