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

Side by Side Diff: chrome/browser/sync/glue/extension_sync.cc

Issue 7624009: Original patch by rlarocque@chromium.org at http://codereview.chromium.org/7633077/ (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix windows build pt5 Created 9 years, 4 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/glue/extension_sync.h" 5 #include "chrome/browser/sync/glue/extension_sync.h"
6 6
7 #include <utility> 7 #include <utility>
8 8
9 #include "base/logging.h" 9 #include "base/logging.h"
10 #include "base/tracked.h" 10 #include "base/tracked.h"
11 #include "chrome/browser/extensions/extension_service.h" 11 #include "chrome/browser/extensions/extension_service.h"
12 #include "chrome/browser/extensions/extension_sync_data.h" 12 #include "chrome/browser/extensions/extension_sync_data.h"
13 #include "chrome/browser/sync/engine/syncapi.h"
14 #include "chrome/browser/sync/glue/extension_sync_traits.h" 13 #include "chrome/browser/sync/glue/extension_sync_traits.h"
15 #include "chrome/browser/sync/glue/extension_util.h" 14 #include "chrome/browser/sync/glue/extension_util.h"
15 #include "chrome/browser/sync/internal_api/read_node.h"
16 #include "chrome/browser/sync/internal_api/read_transaction.h"
17 #include "chrome/browser/sync/internal_api/write_node.h"
18 #include "chrome/browser/sync/internal_api/write_transaction.h"
16 #include "chrome/browser/sync/protocol/extension_specifics.pb.h" 19 #include "chrome/browser/sync/protocol/extension_specifics.pb.h"
17 20
18 namespace browser_sync { 21 namespace browser_sync {
19 22
20 bool RootNodeHasChildren(const char* tag, 23 bool RootNodeHasChildren(const char* tag,
21 sync_api::UserShare* user_share, 24 sync_api::UserShare* user_share,
22 bool* has_children) { 25 bool* has_children) {
23 CHECK(has_children); 26 CHECK(has_children);
24 *has_children = false; 27 *has_children = false;
25 sync_api::ReadTransaction trans(FROM_HERE, user_share); 28 sync_api::ReadTransaction trans(FROM_HERE, user_share);
(...skipping 183 matching lines...) Expand 10 before | Expand all | Expand 10 after
209 sync_api::WriteTransaction trans(FROM_HERE, user_share); 212 sync_api::WriteTransaction trans(FROM_HERE, user_share);
210 sync_api::WriteNode write_node(&trans); 213 sync_api::WriteNode write_node(&trans);
211 if (write_node.InitByClientTagLookup(traits.model_type, id)) { 214 if (write_node.InitByClientTagLookup(traits.model_type, id)) {
212 write_node.Remove(); 215 write_node.Remove();
213 } else { 216 } else {
214 LOG(ERROR) << "Server data does not exist for extension " << id; 217 LOG(ERROR) << "Server data does not exist for extension " << id;
215 } 218 }
216 } 219 }
217 220
218 } // namespace browser_sync 221 } // namespace browser_sync
OLDNEW
« no previous file with comments | « chrome/browser/sync/glue/extension_model_associator.cc ('k') | chrome/browser/sync/glue/extension_sync_traits.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698