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

Unified Diff: components/metrics/clean_exit_beacon.cc

Issue 2687393004: Gather stability prefs into managing objects. (Closed)
Patch Set: Incorporate Feedback Created 3 years, 10 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 | « components/metrics/clean_exit_beacon.h ('k') | components/metrics/environment_recorder.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/metrics/clean_exit_beacon.cc
diff --git a/components/metrics/clean_exit_beacon.cc b/components/metrics/clean_exit_beacon.cc
index 8868e0f99a02609963ec0d54c3b5e7a297579360..4bca5d1c39594ba242d8c64367da134a42226059 100644
--- a/components/metrics/clean_exit_beacon.cc
+++ b/components/metrics/clean_exit_beacon.cc
@@ -7,6 +7,7 @@
#include "base/logging.h"
#include "build/build_config.h"
#include "components/metrics/metrics_pref_names.h"
+#include "components/prefs/pref_registry_simple.h"
#include "components/prefs/pref_service.h"
#if defined(OS_WIN)
@@ -62,6 +63,11 @@ CleanExitBeacon::CleanExitBeacon(const base::string16& backup_registry_key,
CleanExitBeacon::~CleanExitBeacon() {
}
+// static
+void CleanExitBeacon::RegisterPrefs(PrefRegistrySimple* registry) {
+ registry->RegisterBooleanPref(prefs::kStabilityExitedCleanly, true);
+}
+
void CleanExitBeacon::WriteBeaconValue(bool value) {
local_state_->SetBoolean(prefs::kStabilityExitedCleanly, value);
« no previous file with comments | « components/metrics/clean_exit_beacon.h ('k') | components/metrics/environment_recorder.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698