| OLD | NEW |
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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/sync/sessions/status_controller.h" | 5 #include "chrome/browser/sync/sessions/status_controller.h" |
| 6 | 6 |
| 7 #include <vector> | 7 #include <vector> |
| 8 | 8 |
| 9 #include "base/basictypes.h" | 9 #include "base/basictypes.h" |
| 10 #include "chrome/browser/sync/protocol/sync_protocol_error.h" | 10 #include "chrome/browser/sync/protocol/sync_protocol_error.h" |
| (...skipping 193 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 204 | 204 |
| 205 void StatusController::increment_num_server_overwrites() { | 205 void StatusController::increment_num_server_overwrites() { |
| 206 shared_.syncer_status.mutate()->num_server_overwrites++; | 206 shared_.syncer_status.mutate()->num_server_overwrites++; |
| 207 } | 207 } |
| 208 | 208 |
| 209 void StatusController::set_sync_protocol_error( | 209 void StatusController::set_sync_protocol_error( |
| 210 const SyncProtocolError& error) { | 210 const SyncProtocolError& error) { |
| 211 shared_.error.mutate()->sync_protocol_error = error; | 211 shared_.error.mutate()->sync_protocol_error = error; |
| 212 } | 212 } |
| 213 | 213 |
| 214 void StatusController::set_last_download_updates_result( |
| 215 const SyncerError result) { |
| 216 shared_.error.mutate()->last_download_updates_result = result; |
| 217 } |
| 218 |
| 219 void StatusController::set_last_post_commit_result(const SyncerError result) { |
| 220 shared_.error.mutate()->last_post_commit_result = result; |
| 221 } |
| 222 |
| 223 void StatusController::set_last_process_commit_response_result( |
| 224 const SyncerError result) { |
| 225 shared_.error.mutate()->last_process_commit_response_result = result; |
| 226 } |
| 227 |
| 214 void StatusController::set_commit_set(const OrderedCommitSet& commit_set) { | 228 void StatusController::set_commit_set(const OrderedCommitSet& commit_set) { |
| 215 DCHECK(!group_restriction_in_effect_); | 229 DCHECK(!group_restriction_in_effect_); |
| 216 shared_.commit_set = commit_set; | 230 shared_.commit_set = commit_set; |
| 217 } | 231 } |
| 218 | 232 |
| 219 void StatusController::update_conflict_sets_built(bool built) { | 233 void StatusController::update_conflict_sets_built(bool built) { |
| 220 shared_.control_params.conflict_sets_built |= built; | 234 shared_.control_params.conflict_sets_built |= built; |
| 221 } | 235 } |
| 222 void StatusController::update_conflicts_resolved(bool resolved) { | 236 void StatusController::update_conflicts_resolved(bool resolved) { |
| 223 shared_.control_params.conflict_sets_built |= resolved; | 237 shared_.control_params.conflict_sets_built |= resolved; |
| (...skipping 74 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 298 void StatusController::set_debug_info_sent() { | 312 void StatusController::set_debug_info_sent() { |
| 299 shared_.control_params.debug_info_sent = true; | 313 shared_.control_params.debug_info_sent = true; |
| 300 } | 314 } |
| 301 | 315 |
| 302 bool StatusController::debug_info_sent() const { | 316 bool StatusController::debug_info_sent() const { |
| 303 return shared_.control_params.debug_info_sent; | 317 return shared_.control_params.debug_info_sent; |
| 304 } | 318 } |
| 305 | 319 |
| 306 } // namespace sessions | 320 } // namespace sessions |
| 307 } // namespace browser_sync | 321 } // namespace browser_sync |
| OLD | NEW |