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

Unified Diff: components/data_reduction_proxy/core/browser/data_reduction_proxy_statistics_prefs.h

Issue 644883006: Pref to update daily content lengths with the latest values. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Add new include Created 6 years, 2 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: components/data_reduction_proxy/core/browser/data_reduction_proxy_statistics_prefs.h
diff --git a/components/data_reduction_proxy/core/browser/data_reduction_proxy_statistics_prefs.h b/components/data_reduction_proxy/core/browser/data_reduction_proxy_statistics_prefs.h
index 97662957e1e8825fde60a6011ca27d54e73b24a3..7b959df52c53d4847c76e8ba918774872a4316dc 100644
--- a/components/data_reduction_proxy/core/browser/data_reduction_proxy_statistics_prefs.h
+++ b/components/data_reduction_proxy/core/browser/data_reduction_proxy_statistics_prefs.h
@@ -11,9 +11,11 @@
#include "base/macros.h"
#include "base/memory/ref_counted.h"
#include "base/memory/weak_ptr.h"
+#include "base/threading/thread_checker.h"
#include "base/time/time.h"
#include "components/data_reduction_proxy/core/common/data_reduction_proxy_pref_names.h"
+class PrefChangeRegistrar;
class PrefService;
namespace base {
@@ -45,6 +47,10 @@ public:
// |list_pref_map_|.
void Init();
+ void ShutdownOnUIThread();
+
+ void OnUpdateContentLengths();
+
// Gets the int64 pref at |pref_path| from the |DataReductionProxyPrefMap|.
int64 GetInt64(const char* pref_path);
@@ -92,6 +98,8 @@ private:
DataReductionProxyPrefMap pref_map_;
DataReductionProxyListPrefMap list_pref_map_;
base::WeakPtrFactory<DataReductionProxyStatisticsPrefs> weak_factory_;
+ scoped_ptr<PrefChangeRegistrar> pref_change_registrar_;
+ base::ThreadChecker thread_checker_;
DISALLOW_COPY_AND_ASSIGN(DataReductionProxyStatisticsPrefs);
};

Powered by Google App Engine
This is Rietveld 408576698