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

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

Issue 1161006: Make it clear what last_sync_timestamp actually tracks. Update (Closed)
Patch Set: Undo accidental patch-juggling mistake. Created 10 years, 9 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 (c) 2009 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2009 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 #include "chrome/browser/sync/syncable/directory_manager.h" 6 #include "chrome/browser/sync/syncable/directory_manager.h"
7 7
8 namespace browser_sync { 8 namespace browser_sync {
9 namespace sessions { 9 namespace sessions {
10 10
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after
46 sync_pb::GetUpdatesCallerInfo::GetUpdatesSource old_source = source_; 46 sync_pb::GetUpdatesCallerInfo::GetUpdatesSource old_source = source_;
47 set_source(sync_pb::GetUpdatesCallerInfo::SYNC_CYCLE_CONTINUATION); 47 set_source(sync_pb::GetUpdatesCallerInfo::SYNC_CYCLE_CONTINUATION);
48 return old_source; 48 return old_source;
49 } 49 }
50 50
51 bool SyncSession::HasMoreToSync() const { 51 bool SyncSession::HasMoreToSync() const {
52 const StatusController* status = status_controller_.get(); 52 const StatusController* status = status_controller_.get();
53 return ((status->commit_ids().size() < status->unsynced_handles().size()) && 53 return ((status->commit_ids().size() < status->unsynced_handles().size()) &&
54 status->syncer_status().num_successful_commits > 0) || 54 status->syncer_status().num_successful_commits > 0) ||
55 status->conflict_sets_built() || 55 status->conflict_sets_built() ||
56 status->conflicts_resolved() || 56 status->conflicts_resolved();
57 // Or, we have conflicting updates, but we're making progress on 57 // Or, we have conflicting updates, but we're making progress on
58 // resolving them... 58 // resolving them...
59 !status->got_zero_updates() || 59 }
60 status->got_new_timestamp();
61 }
62 60
63 } // namespace sessions 61 } // namespace sessions
64 } // namespace browser_sync 62 } // namespace browser_sync
OLDNEW
« no previous file with comments | « chrome/browser/sync/sessions/status_controller_unittest.cc ('k') | chrome/browser/sync/sessions/sync_session_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698