Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1095)

Unified Diff: chrome/browser/ui/browser.cc

Issue 8086002: Add metrics to help measure effects of installing default apps in a profile. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 9 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: chrome/browser/ui/browser.cc
===================================================================
--- chrome/browser/ui/browser.cc (revision 103269)
+++ chrome/browser/ui/browser.cc (working copy)
@@ -15,6 +15,7 @@
#include "base/base_paths.h"
#include "base/command_line.h"
#include "base/logging.h"
+#include "base/metrics/field_trial.h"
#include "base/metrics/histogram.h"
#include "base/path_service.h"
#include "base/string_number_conversions.h"
@@ -41,6 +42,7 @@
#include "chrome/browser/download/download_item_model.h"
#include "chrome/browser/download/download_started_animation.h"
#include "chrome/browser/extensions/crx_installer.h"
+#include "chrome/browser/extensions/default_apps_trial.h"
#include "chrome/browser/extensions/extension_browser_event_router.h"
#include "chrome/browser/extensions/extension_disabled_infobar_delegate.h"
#include "chrome/browser/extensions/extension_host.h"
@@ -696,9 +698,13 @@
extension->id(), ExtensionPrefs::LAUNCH_DEFAULT);
UMA_HISTOGRAM_ENUMERATION("Extensions.AppTabLaunchType", launch_type, 100);
- // Track launches of the webstore specifically.
- if (extension->id() == extension_misc::kWebStoreAppId)
- UserMetrics::RecordAction(UserMetricsAction("Extensions.WebStoreLaunch"));
+ static bool default_apps_trial_exists = base::FieldTrialList::TrialExists(
+ kDefaultAppsTrial_Name);
+ if (default_apps_trial_exists) {
+ UMA_HISTOGRAM_ENUMERATION(base::FieldTrial::MakeName(
+ "Extensions.AppTabLaunchType", kDefaultAppsTrial_Name),
+ launch_type, 100);
sky 2011/09/29 19:11:09 nit: spacing looks weird on this line.
Roger Tawa OOO till Jul 10th 2011/09/29 19:20:18 Adjusting the spacing in a few places makes the co
+ }
int add_type = TabStripModel::ADD_ACTIVE;
if (launch_type == ExtensionPrefs::LAUNCH_PINNED)

Powered by Google App Engine
This is Rietveld 408576698