Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 78ccf9c3 authored by Brian Isganitis's avatar Brian Isganitis Committed by Android (Google) Code Review
Browse files

Merge "Adding TASKBAR entry state for Taskbar Toast." into main

parents 940fbe1e 257193a6
Loading
Loading
Loading
Loading
+5 −0
Original line number Diff line number Diff line
@@ -41,6 +41,7 @@ message DeviceSearchResultContainer{
  // For application, it will be the column number in the apps row.
  optional int32 grid_x = 3;

  // LINT.IfChange
  // Next ID = 4
  message SearchAttributes{

@@ -64,6 +65,10 @@ message DeviceSearchResultContainer{

      // User entered by swiping up from overview (using Rocket Gesture).
      OVERVIEW = 3;

      // User entered by tapping the search box in the Taskbar AllApps drawer.
      TASKBAR = 4;
    }
  }
  // LINT.ThenChange(//quickstep/src/com/android/quickstep/logging/StatsLogCompatManager.java)
}
+6 −0
Original line number Diff line number Diff line
@@ -104,6 +104,8 @@ public class StatsLogCompatManager extends StatsLogManager {
    private static final int SEARCH_ATTRIBUTES_DIRECT_MATCH = 1 << 1;
    private static final int SEARCH_ATTRIBUTES_ENTRY_STATE_ALL_APPS = 1 << 2;
    private static final int SEARCH_ATTRIBUTES_ENTRY_STATE_QSB = 1 << 3;
    private static final int SEARCH_ATTRIBUTES_ENTRY_STATE_OVERVIEW = 1 << 4;
    private static final int SEARCH_ATTRIBUTES_ENTRY_STATE_TASKBAR = 1 << 5;

    public static final CopyOnWriteArrayList<StatsLogConsumer> LOGS_CONSUMER =
            new CopyOnWriteArrayList<>();
@@ -856,6 +858,10 @@ public class StatsLogCompatManager extends StatsLogManager {
            response = response | SEARCH_ATTRIBUTES_ENTRY_STATE_ALL_APPS;
        } else if (searchAttributes.getEntryState() == SearchAttributes.EntryState.QSB) {
            response = response | SEARCH_ATTRIBUTES_ENTRY_STATE_QSB;
        } else if (searchAttributes.getEntryState() == SearchAttributes.EntryState.OVERVIEW) {
            response = response | SEARCH_ATTRIBUTES_ENTRY_STATE_OVERVIEW;
        } else if (searchAttributes.getEntryState() == SearchAttributes.EntryState.TASKBAR) {
            response = response | SEARCH_ATTRIBUTES_ENTRY_STATE_TASKBAR;
        }

        return response;