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

Side by Side Diff: chrome/browser/sync/sessions/sync_session.cc

Issue 7621085: Server directed error handling backend code. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: upload before commit. Created 9 years, 3 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 | Annotate | Revision Log
OLDNEW
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/sync_session.h" 5 #include "chrome/browser/sync/sessions/sync_session.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 8
9 #include "chrome/browser/sync/syncable/directory_manager.h" 9 #include "chrome/browser/sync/syncable/directory_manager.h"
10 #include "chrome/browser/sync/syncable/model_type.h" 10 #include "chrome/browser/sync/syncable/model_type.h"
(...skipping 90 matching lines...) Expand 10 before | Expand all | Expand 10 after
101 if (dir->initial_sync_ended_for_type(type)) 101 if (dir->initial_sync_ended_for_type(type))
102 initial_sync_ended.set(type); 102 initial_sync_ended.set(type);
103 else 103 else
104 is_share_useable = false; 104 is_share_useable = false;
105 dir->GetDownloadProgressAsString(type, &download_progress_markers[i]); 105 dir->GetDownloadProgressAsString(type, &download_progress_markers[i]);
106 } 106 }
107 } 107 }
108 108
109 return SyncSessionSnapshot( 109 return SyncSessionSnapshot(
110 status_controller_->syncer_status(), 110 status_controller_->syncer_status(),
111 status_controller_->error_counters(), 111 status_controller_->error(),
112 status_controller_->num_server_changes_remaining(), 112 status_controller_->num_server_changes_remaining(),
113 is_share_useable, 113 is_share_useable,
114 initial_sync_ended, 114 initial_sync_ended,
115 download_progress_markers, 115 download_progress_markers,
116 HasMoreToSync(), 116 HasMoreToSync(),
117 delegate_->IsSyncingCurrentlySilenced(), 117 delegate_->IsSyncingCurrentlySilenced(),
118 status_controller_->unsynced_handles().size(), 118 status_controller_->unsynced_handles().size(),
119 status_controller_->TotalNumBlockingConflictingItems(), 119 status_controller_->TotalNumBlockingConflictingItems(),
120 status_controller_->TotalNumConflictingItems(), 120 status_controller_->TotalNumConflictingItems(),
121 status_controller_->did_commit_items(), 121 status_controller_->did_commit_items(),
(...skipping 15 matching lines...) Expand all
137 return ((status->commit_ids().size() < status->unsynced_handles().size()) && 137 return ((status->commit_ids().size() < status->unsynced_handles().size()) &&
138 status->syncer_status().num_successful_commits > 0) || 138 status->syncer_status().num_successful_commits > 0) ||
139 status->conflict_sets_built() || 139 status->conflict_sets_built() ||
140 status->conflicts_resolved(); 140 status->conflicts_resolved();
141 // Or, we have conflicting updates, but we're making progress on 141 // Or, we have conflicting updates, but we're making progress on
142 // resolving them... 142 // resolving them...
143 } 143 }
144 144
145 } // namespace sessions 145 } // namespace sessions
146 } // namespace browser_sync 146 } // namespace browser_sync
OLDNEW
« no previous file with comments | « chrome/browser/sync/sessions/sync_session.h ('k') | chrome/browser/sync/sessions/sync_session_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698