| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "chrome/browser/prefs/pref_hash_store_impl.h" | 5 #include "chrome/browser/prefs/tracked/pref_hash_store_impl.h" |
| 6 | 6 |
| 7 #include "base/logging.h" | 7 #include "base/logging.h" |
| 8 #include "base/metrics/histogram.h" | 8 #include "base/metrics/histogram.h" |
| 9 #include "base/values.h" | 9 #include "base/values.h" |
| 10 #include "chrome/browser/prefs/pref_hash_store_transaction.h" | |
| 11 #include "chrome/browser/prefs/tracked/hash_store_contents.h" | 10 #include "chrome/browser/prefs/tracked/hash_store_contents.h" |
| 11 #include "chrome/browser/prefs/tracked/pref_hash_store_transaction.h" |
| 12 | 12 |
| 13 class PrefHashStoreImpl::PrefHashStoreTransactionImpl | 13 class PrefHashStoreImpl::PrefHashStoreTransactionImpl |
| 14 : public PrefHashStoreTransaction { | 14 : public PrefHashStoreTransaction { |
| 15 public: | 15 public: |
| 16 // Constructs a PrefHashStoreTransactionImpl which can use the private | 16 // Constructs a PrefHashStoreTransactionImpl which can use the private |
| 17 // members of its |outer| PrefHashStoreImpl. | 17 // members of its |outer| PrefHashStoreImpl. |
| 18 PrefHashStoreTransactionImpl(PrefHashStoreImpl* outer, | 18 PrefHashStoreTransactionImpl(PrefHashStoreImpl* outer, |
| 19 scoped_ptr<HashStoreContents> storage); | 19 scoped_ptr<HashStoreContents> storage); |
| 20 virtual ~PrefHashStoreTransactionImpl(); | 20 virtual ~PrefHashStoreTransactionImpl(); |
| 21 | 21 |
| (...skipping 280 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 302 bool PrefHashStoreImpl::PrefHashStoreTransactionImpl::IsSuperMACValid() const { | 302 bool PrefHashStoreImpl::PrefHashStoreTransactionImpl::IsSuperMACValid() const { |
| 303 return super_mac_valid_; | 303 return super_mac_valid_; |
| 304 } | 304 } |
| 305 | 305 |
| 306 bool PrefHashStoreImpl::PrefHashStoreTransactionImpl::StampSuperMac() { | 306 bool PrefHashStoreImpl::PrefHashStoreTransactionImpl::StampSuperMac() { |
| 307 if (!outer_->use_super_mac_ || super_mac_valid_) | 307 if (!outer_->use_super_mac_ || super_mac_valid_) |
| 308 return false; | 308 return false; |
| 309 super_mac_dirty_ = true; | 309 super_mac_dirty_ = true; |
| 310 return true; | 310 return true; |
| 311 } | 311 } |
| OLD | NEW |