Commit 085b583f authored by David Bienvenu's avatar David Bienvenu Committed by Commit Bot

Make Launch.Modes an enum histogram, not sparse.

In response to comment on crrev.com/c/2384332.

Per mpearson@: For enums versus sparses, the underlying UMA
data / logs will look the same.  It's only the implementation
in Chromium that would be different.

Change-Id: Ia75d78379977f36ec7873d5fb5d52998e6a366d3
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2429975Reviewed-by: default avatarPeter Boström <pbos@chromium.org>
Commit-Queue: David Bienvenu <davidbienvenu@chromium.org>
Cr-Commit-Position: refs/heads/master@{#810438}
parent 67def4fd
...@@ -148,8 +148,8 @@ void RecordLaunchModeHistogram(LaunchMode mode) { ...@@ -148,8 +148,8 @@ void RecordLaunchModeHistogram(LaunchMode mode) {
{base::TaskPriority::BEST_EFFORT, {base::TaskPriority::BEST_EFFORT,
base::TaskShutdownBehavior::CONTINUE_ON_SHUTDOWN}, base::TaskShutdownBehavior::CONTINUE_ON_SHUTDOWN},
base::BindOnce([]() { base::BindOnce([]() {
base::UmaHistogramSparse(kLaunchModesHistogram, base::UmaHistogramEnumeration(kLaunchModesHistogram,
static_cast<int>(GetLaunchModeSlow())); GetLaunchModeSlow());
})); }));
} else { } else {
base::UmaHistogramSparse(kLaunchModesHistogram, static_cast<int>(mode)); base::UmaHistogramSparse(kLaunchModesHistogram, static_cast<int>(mode));
......
...@@ -40,6 +40,7 @@ enum class LaunchMode { ...@@ -40,6 +40,7 @@ enum class LaunchMode {
// Launched as an installed web application in a browser tab. // Launched as an installed web application in a browser tab.
kAsWebAppInTab = 21, kAsWebAppInTab = 21,
kUnknownWebApp = 22, // The requested web application was not installed. kUnknownWebApp = 22, // The requested web application was not installed.
kMaxValue = 22,
}; };
class LaunchModeRecorder { class LaunchModeRecorder {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment