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

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

Issue 10147003: [Sync] Move 'syncapi_core' and 'sync_unit_tests' targets to sync/ (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix Win update errors Created 8 years, 8 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) 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 "chrome/browser/sync/glue/theme_model_associator.h" 5 #include "chrome/browser/sync/glue/theme_model_associator.h"
6 6
7 #include "base/basictypes.h" 7 #include "base/basictypes.h"
8 #include "base/location.h" 8 #include "base/location.h"
9 #include "base/logging.h" 9 #include "base/logging.h"
10 #include "base/utf_string_conversions.h" 10 #include "base/utf_string_conversions.h"
11 #include "chrome/browser/sync/api/sync_error.h" 11 #include "chrome/browser/sync/api/sync_error.h"
12 #include "chrome/browser/sync/glue/sync_backend_host.h" 12 #include "chrome/browser/sync/glue/sync_backend_host.h"
13 #include "chrome/browser/sync/glue/theme_util.h" 13 #include "chrome/browser/sync/glue/theme_util.h"
14 #include "chrome/browser/sync/internal_api/read_node.h"
15 #include "chrome/browser/sync/internal_api/read_transaction.h"
16 #include "chrome/browser/sync/internal_api/write_node.h"
17 #include "chrome/browser/sync/internal_api/write_transaction.h"
18 #include "chrome/browser/sync/profile_sync_service.h" 14 #include "chrome/browser/sync/profile_sync_service.h"
15 #include "sync/internal_api/read_node.h"
16 #include "sync/internal_api/read_transaction.h"
17 #include "sync/internal_api/write_node.h"
18 #include "sync/internal_api/write_transaction.h"
19 #include "sync/protocol/theme_specifics.pb.h" 19 #include "sync/protocol/theme_specifics.pb.h"
20 20
21 namespace browser_sync { 21 namespace browser_sync {
22 22
23 namespace { 23 namespace {
24 24
25 static const char kThemesTag[] = "google_chrome_themes"; 25 static const char kThemesTag[] = "google_chrome_themes";
26 static const char kCurrentThemeNodeTitle[] = "Current Theme"; 26 static const char kCurrentThemeNodeTitle[] = "Current Theme";
27 27
28 static const char kNoThemesFolderError[] = 28 static const char kNoThemesFolderError[] =
(...skipping 78 matching lines...) Expand 10 before | Expand all | Expand 10 after
107 bool ThemeModelAssociator::CryptoReadyIfNecessary() { 107 bool ThemeModelAssociator::CryptoReadyIfNecessary() {
108 // We only access the cryptographer while holding a transaction. 108 // We only access the cryptographer while holding a transaction.
109 sync_api::ReadTransaction trans(FROM_HERE, sync_service_->GetUserShare()); 109 sync_api::ReadTransaction trans(FROM_HERE, sync_service_->GetUserShare());
110 const syncable::ModelTypeSet encrypted_types = 110 const syncable::ModelTypeSet encrypted_types =
111 sync_api::GetEncryptedTypes(&trans); 111 sync_api::GetEncryptedTypes(&trans);
112 return !encrypted_types.Has(syncable::THEMES) || 112 return !encrypted_types.Has(syncable::THEMES) ||
113 sync_service_->IsCryptographerReady(&trans); 113 sync_service_->IsCryptographerReady(&trans);
114 } 114 }
115 115
116 } // namespace browser_sync 116 } // namespace browser_sync
OLDNEW
« no previous file with comments | « chrome/browser/sync/glue/theme_change_processor.cc ('k') | chrome/browser/sync/glue/typed_url_change_processor.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698