diff options
author | danakj <danakj@chromium.org> | 2015-09-24 00:53:00 -0700 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2015-09-24 07:53:38 +0000 |
commit | 8c3eb804c56b7173f00e58e040f47fe867dabda7 (patch) | |
tree | 3dee4211092c1942e4eaf24684f3255cfddd9e34 /storage | |
parent | f7033f79311149ae641bcaa3986c753f60f1db7e (diff) | |
download | chromium_src-8c3eb804c56b7173f00e58e040f47fe867dabda7.zip chromium_src-8c3eb804c56b7173f00e58e040f47fe867dabda7.tar.gz chromium_src-8c3eb804c56b7173f00e58e040f47fe867dabda7.tar.bz2 |
base: Template methods on Timer classes instead of the classes themselves.
The base class for OneShotTimer and DelayedTimer is templated but
only the Start method needs to be (which has a TODO to make it go away
entirely too).
The DelayedTimer class is also templated but only its constructor
needs to be, and the type can be inferred at the callsite, so less
typing all around.
R=thakis@chromium.org
TBR=sky,brettw
BUG=148832
CQ_INCLUDE_TRYBOTS=tryserver.blink:linux_blink_rel
Review URL: https://codereview.chromium.org/1355063004
Cr-Commit-Position: refs/heads/master@{#350496}
Diffstat (limited to 'storage')
-rw-r--r-- | storage/browser/quota/quota_database.h | 2 | ||||
-rw-r--r-- | storage/browser/quota/quota_manager.h | 2 | ||||
-rw-r--r-- | storage/browser/quota/quota_temporary_storage_evictor.h | 4 | ||||
-rw-r--r-- | storage/browser/quota/storage_monitor.h | 2 |
4 files changed, 5 insertions, 5 deletions
diff --git a/storage/browser/quota/quota_database.h b/storage/browser/quota/quota_database.h index 6ca5651..7112666 100644 --- a/storage/browser/quota/quota_database.h +++ b/storage/browser/quota/quota_database.h @@ -174,7 +174,7 @@ class STORAGE_EXPORT_PRIVATE QuotaDatabase { bool is_recreating_; bool is_disabled_; - base::OneShotTimer<QuotaDatabase> timer_; + base::OneShotTimer timer_; friend class content::QuotaDatabaseTest; friend class QuotaManager; diff --git a/storage/browser/quota/quota_manager.h b/storage/browser/quota/quota_manager.h index 506aa0a..3e05388 100644 --- a/storage/browser/quota/quota_manager.h +++ b/storage/browser/quota/quota_manager.h @@ -452,7 +452,7 @@ class STORAGE_EXPORT QuotaManager scoped_refptr<SpecialStoragePolicy> special_storage_policy_; - base::RepeatingTimer<QuotaManager> histogram_timer_; + base::RepeatingTimer histogram_timer_; // Pointer to the function used to get the available disk space. This is // overwritten by QuotaManagerTest in order to attain a deterministic reported diff --git a/storage/browser/quota/quota_temporary_storage_evictor.h b/storage/browser/quota/quota_temporary_storage_evictor.h index a32b6c8..9b896e9 100644 --- a/storage/browser/quota/quota_temporary_storage_evictor.h +++ b/storage/browser/quota/quota_temporary_storage_evictor.h @@ -122,8 +122,8 @@ class STORAGE_EXPORT_PRIVATE QuotaTemporaryStorageEvictor int64 interval_ms_; bool repeated_eviction_; - base::OneShotTimer<QuotaTemporaryStorageEvictor> eviction_timer_; - base::RepeatingTimer<QuotaTemporaryStorageEvictor> histogram_timer_; + base::OneShotTimer eviction_timer_; + base::RepeatingTimer histogram_timer_; base::WeakPtrFactory<QuotaTemporaryStorageEvictor> weak_factory_; DISALLOW_COPY_AND_ASSIGN(QuotaTemporaryStorageEvictor); diff --git a/storage/browser/quota/storage_monitor.h b/storage/browser/quota/storage_monitor.h index 650c7b1..8c7960f 100644 --- a/storage/browser/quota/storage_monitor.h +++ b/storage/browser/quota/storage_monitor.h @@ -60,7 +60,7 @@ class STORAGE_EXPORT_PRIVATE StorageObserverList { void DispatchPendingEvent(); StorageObserverStateMap observers_; - base::OneShotTimer<StorageObserverList> notification_timer_; + base::OneShotTimer notification_timer_; StorageObserver::Event pending_event_; friend class content::StorageMonitorTestBase; |