OLD | NEW |
(Empty) | |
| 1 // Copyright (c) 2006-2009 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. |
| 4 |
| 5 #include "chrome/browser/sync/engine/resolve_conflicts_command.h" |
| 6 |
| 7 #include "chrome/browser/sync/engine/conflict_resolver.h" |
| 8 #include "chrome/browser/sync/engine/syncer_session.h" |
| 9 #include "chrome/browser/sync/syncable/directory_manager.h" |
| 10 |
| 11 namespace browser_sync { |
| 12 |
| 13 ResolveConflictsCommand::ResolveConflictsCommand() {} |
| 14 ResolveConflictsCommand::~ResolveConflictsCommand() {} |
| 15 |
| 16 void ResolveConflictsCommand::ModelChangingExecuteImpl( |
| 17 SyncerSession* session) { |
| 18 if (!session->resolver()) |
| 19 return; |
| 20 syncable::ScopedDirLookup dir(session->dirman(), session->account_name()); |
| 21 if (!dir.good()) |
| 22 return; |
| 23 ConflictResolutionView conflict_view(session); |
| 24 session->set_conflicts_resolved( |
| 25 session->resolver()->ResolveConflicts(dir, &conflict_view, session)); |
| 26 } |
| 27 |
| 28 } // namespace browser_sync |
OLD | NEW |