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

Side by Side Diff: components/browsing_data/core/counters/browsing_data_counter.cc

Issue 2855623005: Move browsing_data counter sync tests to separate file (Closed)
Patch Set: remove HistoryResult and PasswordResult Created 3 years, 7 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 unified diff | Download patch
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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 "components/browsing_data/core/counters/browsing_data_counter.h" 5 #include "components/browsing_data/core/counters/browsing_data_counter.h"
6 6
7 #include <utility> 7 #include <utility>
8 8
9 #include "base/memory/ptr_util.h" 9 #include "base/memory/ptr_util.h"
10 #include "components/browsing_data/core/browsing_data_utils.h" 10 #include "components/browsing_data/core/browsing_data_utils.h"
(...skipping 149 matching lines...) Expand 10 before | Expand all | Expand 10 after
160 160
161 bool BrowsingDataCounter::FinishedResult::Finished() const { 161 bool BrowsingDataCounter::FinishedResult::Finished() const {
162 return true; 162 return true;
163 } 163 }
164 164
165 BrowsingDataCounter::ResultInt BrowsingDataCounter::FinishedResult::Value() 165 BrowsingDataCounter::ResultInt BrowsingDataCounter::FinishedResult::Value()
166 const { 166 const {
167 return value_; 167 return value_;
168 } 168 }
169 169
170 // BrowsingDataCounter::SyncResult -----------------------------------------
171
172 BrowsingDataCounter::SyncResult::SyncResult(const BrowsingDataCounter* source,
173 ResultInt value,
174 bool sync_enabled)
175 : FinishedResult(source, value), sync_enabled_(sync_enabled) {}
176
177 BrowsingDataCounter::SyncResult::~SyncResult() {}
178
179 bool BrowsingDataCounter::SyncResult::IsSyncEnabled() const {
msramek 2017/05/11 15:49:14 style nit: Simple non-virtual getters and setters
dullweber 2017/05/12 13:37:31 done. Is Value() using the wrong style then?
msramek 2017/05/15 17:56:53 Hmm, apparently so. It was probably virtual at one
180 return sync_enabled_;
181 }
182
170 } // namespace browsing_data 183 } // namespace browsing_data
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698