OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 "sync/sessions/status_controller.h" | 5 #include "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 "sync/internal_api/public/base/model_type.h" | 10 #include "sync/internal_api/public/base/model_type.h" |
(...skipping 14 matching lines...) Expand all Loading... |
25 void StatusController::increment_num_tombstone_updates_downloaded_by( | 25 void StatusController::increment_num_tombstone_updates_downloaded_by( |
26 int value) { | 26 int value) { |
27 model_neutral_.num_tombstone_updates_downloaded_total += value; | 27 model_neutral_.num_tombstone_updates_downloaded_total += value; |
28 } | 28 } |
29 | 29 |
30 void StatusController::increment_num_reflected_updates_downloaded_by( | 30 void StatusController::increment_num_reflected_updates_downloaded_by( |
31 int value) { | 31 int value) { |
32 model_neutral_.num_reflected_updates_downloaded_total += value; | 32 model_neutral_.num_reflected_updates_downloaded_total += value; |
33 } | 33 } |
34 | 34 |
35 void StatusController::set_num_server_changes_remaining( | |
36 int64 changes_remaining) { | |
37 model_neutral_.num_server_changes_remaining = changes_remaining; | |
38 } | |
39 | |
40 void StatusController::UpdateStartTime() { | 35 void StatusController::UpdateStartTime() { |
41 sync_start_time_ = base::Time::Now(); | 36 sync_start_time_ = base::Time::Now(); |
42 } | 37 } |
43 | 38 |
44 void StatusController::set_num_successful_bookmark_commits(int value) { | 39 void StatusController::set_num_successful_bookmark_commits(int value) { |
45 model_neutral_.num_successful_bookmark_commits = value; | 40 model_neutral_.num_successful_bookmark_commits = value; |
46 } | 41 } |
47 | 42 |
48 void StatusController::increment_num_successful_bookmark_commits() { | 43 void StatusController::increment_num_successful_bookmark_commits() { |
49 model_neutral_.num_successful_bookmark_commits++; | 44 model_neutral_.num_successful_bookmark_commits++; |
(...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
117 int StatusController::TotalNumConflictingItems() const { | 112 int StatusController::TotalNumConflictingItems() const { |
118 int sum = 0; | 113 int sum = 0; |
119 sum += num_encryption_conflicts(); | 114 sum += num_encryption_conflicts(); |
120 sum += num_hierarchy_conflicts(); | 115 sum += num_hierarchy_conflicts(); |
121 sum += num_server_conflicts(); | 116 sum += num_server_conflicts(); |
122 return sum; | 117 return sum; |
123 } | 118 } |
124 | 119 |
125 } // namespace sessions | 120 } // namespace sessions |
126 } // namespace syncer | 121 } // namespace syncer |
OLD | NEW |