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

Unified Diff: chrome/browser/chromeos/user_cros_settings_provider.cc

Issue 7518012: Revert 94350 - Merge 94322 - Rewire the metrics pref to the signed settings store on chromeos. (Closed) Base URL: svn://svn.chromium.org/chrome/branches/835/src/
Patch Set: Created 9 years, 5 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
« no previous file with comments | « chrome/browser/chromeos/user_cros_settings_provider.h ('k') | chrome/browser/ui/webui/crashes_ui.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/chromeos/user_cros_settings_provider.cc
===================================================================
--- chrome/browser/chromeos/user_cros_settings_provider.cc (revision 94787)
+++ chrome/browser/chromeos/user_cros_settings_provider.cc (working copy)
@@ -24,8 +24,6 @@
#include "chrome/browser/policy/browser_policy_connector.h"
#include "chrome/browser/prefs/pref_service.h"
#include "chrome/browser/prefs/scoped_user_pref_update.h"
-#include "chrome/browser/ui/options/options_util.h"
-#include "chrome/installer/util/google_update_settings.h"
#include "content/browser/browser_thread.h"
namespace chromeos {
@@ -44,7 +42,6 @@
kAccountsPrefAllowGuest,
kAccountsPrefShowUserNamesOnSignIn,
kSignedDataRoamingEnabled,
- kStatsReportingPref
};
const char* kStringSettings[] = {
@@ -63,8 +60,7 @@
return (pref_path == kAccountsPrefAllowNewUser) ||
(pref_path == kAccountsPrefAllowGuest) ||
(pref_path == kAccountsPrefShowUserNamesOnSignIn) ||
- (pref_path == kSignedDataRoamingEnabled) ||
- (pref_path == kStatsReportingPref);
+ (pref_path == kSignedDataRoamingEnabled);
}
bool IsControlledStringSetting(const std::string& pref_path) {
@@ -86,8 +82,7 @@
false,
PrefService::UNSYNCABLE_PREF);
if (IsControlledBooleanSetting(pref_path)) {
- if (pref_path == kSignedDataRoamingEnabled ||
- pref_path == kStatsReportingPref)
+ if (pref_path == kSignedDataRoamingEnabled)
local_state->RegisterBooleanPref(pref_path.c_str(),
false,
PrefService::UNSYNCABLE_PREF);
@@ -291,10 +286,6 @@
NetworkLibrary* cros = CrosLibrary::Get()->GetNetworkLibrary();
cros->SetCellularDataRoamingAllowed(new_value);
- } else if (path == kStatsReportingPref) {
- // TODO(pastarmovj): Remove this once we don't need to regenerate the
- // consent file for the GUID anymore.
- OptionsUtil::ResolveMetricsReportingEnabled(new_value);
}
}
@@ -314,13 +305,6 @@
if (device_value != new_value)
cros->SetCellularDataRoamingAllowed(new_value);
}
- } else if (path == kStatsReportingPref) {
- bool stats_consent = (use_value == USE_VALUE_SUPPLIED) ? value : false;
- // TODO(pastarmovj): Remove this once we don't need to regenerate the
- // consent file for the GUID anymore.
- VLOG(1) << "Metrics policy is being set to : " << stats_consent
- << "(reason : " << use_value << ")";
- OptionsUtil::ResolveMetricsReportingEnabled(stats_consent);
}
}
@@ -504,11 +488,6 @@
kDeviceOwner, callback);
}
-bool UserCrosSettingsProvider::RequestTrustedReportingEnabled(Task* callback) {
- return UserCrosSettingsTrust::GetInstance()->RequestTrustedEntity(
- kStatsReportingPref, callback);
-}
-
void UserCrosSettingsProvider::Reload() {
UserCrosSettingsTrust::GetInstance()->Reload();
}
@@ -545,14 +524,6 @@
}
// static
-bool UserCrosSettingsProvider::cached_reporting_enabled() {
- // Trigger prefetching if singleton object still does not exist.
- UserCrosSettingsTrust::GetInstance();
- return g_browser_process->local_state()->GetBoolean(
- kStatsReportingPref);
-}
-
-// static
const ListValue* UserCrosSettingsProvider::cached_whitelist() {
PrefService* prefs = g_browser_process->local_state();
const ListValue* cached_users = prefs->GetList(kAccountsPrefUsers);
@@ -626,7 +597,6 @@
bool UserCrosSettingsProvider::HandlesSetting(const std::string& path) {
return ::StartsWithASCII(path, "cros.accounts.", true) ||
::StartsWithASCII(path, "cros.signed.", true) ||
- ::StartsWithASCII(path, "cros.metrics.", true) ||
path == kReleaseChannel;
}
« no previous file with comments | « chrome/browser/chromeos/user_cros_settings_provider.h ('k') | chrome/browser/ui/webui/crashes_ui.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698