diff options
author | brettw@chromium.org <brettw@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-03-25 17:06:53 +0000 |
---|---|---|
committer | brettw@chromium.org <brettw@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-03-25 17:06:53 +0000 |
commit | 60626dadc27498024d9aefcf64da73d48940e162 (patch) | |
tree | d539d421db61d277b9229c427ddcae2dcaf6aec8 /chrome/common | |
parent | e160e832bc9801b211772a6fb4fca49145a64f76 (diff) | |
download | chromium_src-60626dadc27498024d9aefcf64da73d48940e162.zip chromium_src-60626dadc27498024d9aefcf64da73d48940e162.tar.gz chromium_src-60626dadc27498024d9aefcf64da73d48940e162.tar.bz2 |
Move some stuff from BrowserMain into helper functions.
This patch changes the behavior slightly. We used to skip creation of the
metrics service at all if it was disabled on the command line. But this was
pretty confusing because it was still possible for it to be disabled by way of
not uploading any data. And there were two places in the rest of the function
that would crash if the metrics service was NULL (because you used the command
line switch).
After some archaeology, I discovered the command line switch was from before
we had preferences and was then the only way to disable the metrics. Since we
have prefs now and it defaults to off, I think the command line switch isn't
useful, and the fact that it crashes sometimes further indicates this. So I
just removed it.
This does not remove the actual constant since that's used by ChromeFrame:
once to make sure it's passed through when Chrome is spawend, and once in a
test that command line switches are passed through. We'll have to remove these
in a separate patch before removing the constant declaration.
This also moves the WebSocketExperimentRunner starting from outside the
"disable metrics" block. I think the intent was that it wouldn't be enabled
if we weren't collecting metrics, but it wasn't actually working that way,
so I just pulled it out to the top level of BrowserMain.
TEST=none
BUG=none
Review URL: http://codereview.chromium.org/1251007
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@42629 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/common')
-rw-r--r-- | chrome/common/chrome_switches.cc | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/chrome/common/chrome_switches.cc b/chrome/common/chrome_switches.cc index 6935a15..feaf3a9 100644 --- a/chrome/common/chrome_switches.cc +++ b/chrome/common/chrome_switches.cc @@ -134,7 +134,8 @@ const char kDisableLocalStorage[] = "disable-local-storage"; // builds. const char kDisableLogging[] = "disable-logging"; -// Completely disables UMA metrics system. +// Does nothing, use the preferences to see if the user has enabled metrics. +// TODO(brettw) bug 39224: remove this constant. const char kDisableMetrics[] = "disable-metrics"; // Whether we should prevent the new tab page from showing the first run |