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

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

Issue 2798243004: Show password sync status in CBD (Closed)
Patch Set: add sync test Created 3 years, 8 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 121 matching lines...) Expand 10 before | Expand all | Expand 10 after
132 DoReportResult(std::move(staged_result_)); 132 DoReportResult(std::move(staged_result_));
133 } else { 133 } else {
134 state_ = State::READY_TO_REPORT_RESULT; 134 state_ = State::READY_TO_REPORT_RESULT;
135 state_transitions_.push_back(state_); 135 state_transitions_.push_back(state_);
136 } 136 }
137 } 137 }
138 138
139 // BrowsingDataCounter::Result ------------------------------------------------- 139 // BrowsingDataCounter::Result -------------------------------------------------
140 140
141 BrowsingDataCounter::Result::Result(const BrowsingDataCounter* source) 141 BrowsingDataCounter::Result::Result(const BrowsingDataCounter* source)
142 : source_(source) {} 142 : source_(source) {
143 DCHECK(source);
144 }
143 145
144 BrowsingDataCounter::Result::~Result() {} 146 BrowsingDataCounter::Result::~Result() {}
145 147
146 bool BrowsingDataCounter::Result::Finished() const { 148 bool BrowsingDataCounter::Result::Finished() const {
147 return false; 149 return false;
148 } 150 }
149 151
150 // BrowsingDataCounter::FinishedResult ----------------------------------------- 152 // BrowsingDataCounter::FinishedResult -----------------------------------------
151 153
152 BrowsingDataCounter::FinishedResult::FinishedResult( 154 BrowsingDataCounter::FinishedResult::FinishedResult(
153 const BrowsingDataCounter* source, 155 const BrowsingDataCounter* source,
154 ResultInt value) 156 ResultInt value)
155 : Result(source), value_(value) {} 157 : Result(source), value_(value) {}
156 158
157 BrowsingDataCounter::FinishedResult::~FinishedResult() {} 159 BrowsingDataCounter::FinishedResult::~FinishedResult() {}
158 160
159 bool BrowsingDataCounter::FinishedResult::Finished() const { 161 bool BrowsingDataCounter::FinishedResult::Finished() const {
160 return true; 162 return true;
161 } 163 }
162 164
163 BrowsingDataCounter::ResultInt BrowsingDataCounter::FinishedResult::Value() 165 BrowsingDataCounter::ResultInt BrowsingDataCounter::FinishedResult::Value()
164 const { 166 const {
165 return value_; 167 return value_;
166 } 168 }
167 169
168 } // namespace browsing_data 170 } // namespace browsing_data
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698