| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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/extensions/extension_sync_service.h" | 5 #include "chrome/browser/extensions/extension_sync_service.h" |
| 6 | 6 |
| 7 #include <iterator> | 7 #include <iterator> |
| 8 | 8 |
| 9 #include "base/basictypes.h" | 9 #include "base/basictypes.h" |
| 10 #include "base/threading/sequenced_worker_pool.h" | 10 #include "base/threading/sequenced_worker_pool.h" |
| 11 #include "base/threading/thread_restrictions.h" | 11 #include "base/threading/thread_restrictions.h" |
| 12 #include "chrome/browser/extensions/app_sync_data.h" | 12 #include "chrome/browser/extensions/app_sync_data.h" |
| 13 #include "chrome/browser/extensions/extension_error_ui.h" | 13 #include "chrome/browser/extensions/extension_error_ui.h" |
| 14 #include "chrome/browser/extensions/extension_prefs.h" | |
| 15 #include "chrome/browser/extensions/extension_service.h" | 14 #include "chrome/browser/extensions/extension_service.h" |
| 16 #include "chrome/browser/extensions/extension_sync_data.h" | 15 #include "chrome/browser/extensions/extension_sync_data.h" |
| 17 #include "chrome/browser/extensions/extension_sync_service_factory.h" | 16 #include "chrome/browser/extensions/extension_sync_service_factory.h" |
| 18 #include "chrome/browser/extensions/extension_util.h" | 17 #include "chrome/browser/extensions/extension_util.h" |
| 19 #include "chrome/browser/extensions/launch_util.h" | 18 #include "chrome/browser/extensions/launch_util.h" |
| 20 #include "chrome/browser/profiles/profile.h" | 19 #include "chrome/browser/profiles/profile.h" |
| 21 #include "chrome/browser/sync/glue/sync_start_util.h" | 20 #include "chrome/browser/sync/glue/sync_start_util.h" |
| 22 #include "chrome/browser/sync/sync_prefs.h" | 21 #include "chrome/browser/sync/sync_prefs.h" |
| 23 #include "chrome/common/extensions/sync_helper.h" | 22 #include "chrome/common/extensions/sync_helper.h" |
| 24 #include "content/public/browser/browser_thread.h" | 23 #include "content/public/browser/browser_thread.h" |
| 25 #include "extensions/browser/app_sorting.h" | 24 #include "extensions/browser/app_sorting.h" |
| 25 #include "extensions/browser/extension_prefs.h" |
| 26 #include "extensions/browser/extension_registry.h" | 26 #include "extensions/browser/extension_registry.h" |
| 27 #include "extensions/common/extension.h" | 27 #include "extensions/common/extension.h" |
| 28 #include "extensions/common/feature_switch.h" | 28 #include "extensions/common/feature_switch.h" |
| 29 #include "extensions/common/manifest_constants.h" | 29 #include "extensions/common/manifest_constants.h" |
| 30 #include "sync/api/sync_change.h" | 30 #include "sync/api/sync_change.h" |
| 31 #include "sync/api/sync_error_factory.h" | 31 #include "sync/api/sync_error_factory.h" |
| 32 | 32 |
| 33 using extensions::Extension; | 33 using extensions::Extension; |
| 34 using extensions::ExtensionPrefs; | 34 using extensions::ExtensionPrefs; |
| 35 using extensions::ExtensionRegistry; | 35 using extensions::ExtensionRegistry; |
| (...skipping 421 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 457 app_sync_bundle_.SyncChangeIfNeeded(extension); | 457 app_sync_bundle_.SyncChangeIfNeeded(extension); |
| 458 else if (extension_service_->is_ready() && !flare_.is_null()) | 458 else if (extension_service_->is_ready() && !flare_.is_null()) |
| 459 flare_.Run(syncer::APPS); | 459 flare_.Run(syncer::APPS); |
| 460 } else if (extensions::sync_helper::IsSyncableExtension(&extension)) { | 460 } else if (extensions::sync_helper::IsSyncableExtension(&extension)) { |
| 461 if (extension_sync_bundle_.IsSyncing()) | 461 if (extension_sync_bundle_.IsSyncing()) |
| 462 extension_sync_bundle_.SyncChangeIfNeeded(extension); | 462 extension_sync_bundle_.SyncChangeIfNeeded(extension); |
| 463 else if (extension_service_->is_ready() && !flare_.is_null()) | 463 else if (extension_service_->is_ready() && !flare_.is_null()) |
| 464 flare_.Run(syncer::EXTENSIONS); | 464 flare_.Run(syncer::EXTENSIONS); |
| 465 } | 465 } |
| 466 } | 466 } |
| OLD | NEW |