| OLD | NEW |
| 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/extensions/component_loader.h" | 5 #include "chrome/browser/extensions/component_loader.h" |
| 6 | 6 |
| 7 #include <string> | 7 #include <string> |
| 8 | 8 |
| 9 #include "base/command_line.h" | 9 #include "base/command_line.h" |
| 10 #include "base/files/file_util.h" | 10 #include "base/files/file_util.h" |
| (...skipping 430 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 441 #endif | 441 #endif |
| 442 } | 442 } |
| 443 | 443 |
| 444 void ComponentLoader::AddKeyboardApp() { | 444 void ComponentLoader::AddKeyboardApp() { |
| 445 #if defined(OS_CHROMEOS) | 445 #if defined(OS_CHROMEOS) |
| 446 Add(IDR_KEYBOARD_MANIFEST, base::FilePath(FILE_PATH_LITERAL("keyboard"))); | 446 Add(IDR_KEYBOARD_MANIFEST, base::FilePath(FILE_PATH_LITERAL("keyboard"))); |
| 447 #endif | 447 #endif |
| 448 } | 448 } |
| 449 | 449 |
| 450 void ComponentLoader::AddWebStoreApp() { | 450 void ComponentLoader::AddWebStoreApp() { |
| 451 #if defined(OS_CHROMEOS) |
| 452 if (!IsNormalSession()) |
| 453 return; |
| 454 #endif |
| 455 |
| 451 AddWithNameAndDescription(IDR_WEBSTORE_MANIFEST, | 456 AddWithNameAndDescription(IDR_WEBSTORE_MANIFEST, |
| 452 base::FilePath(FILE_PATH_LITERAL("web_store")), | 457 base::FilePath(FILE_PATH_LITERAL("web_store")), |
| 453 IDS_WEBSTORE_NAME_STORE, | 458 IDS_WEBSTORE_NAME_STORE, |
| 454 IDS_WEBSTORE_APP_DESCRIPTION); | 459 IDS_WEBSTORE_APP_DESCRIPTION); |
| 455 } | 460 } |
| 456 | 461 |
| 457 // static | 462 // static |
| 458 void ComponentLoader::EnableBackgroundExtensionsForTesting() { | 463 void ComponentLoader::EnableBackgroundExtensionsForTesting() { |
| 459 enable_background_extensions_during_testing = true; | 464 enable_background_extensions_during_testing = true; |
| 460 } | 465 } |
| (...skipping 211 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 672 off_the_record_context, Extension::GetBaseURLFromExtensionId(id)); | 677 off_the_record_context, Extension::GetBaseURLFromExtensionId(id)); |
| 673 storage::FileSystemContext* file_system_context = | 678 storage::FileSystemContext* file_system_context = |
| 674 content::BrowserContext::GetStoragePartitionForSite( | 679 content::BrowserContext::GetStoragePartitionForSite( |
| 675 off_the_record_context, site)->GetFileSystemContext(); | 680 off_the_record_context, site)->GetFileSystemContext(); |
| 676 file_system_context->EnableTemporaryFileSystemInIncognito(); | 681 file_system_context->EnableTemporaryFileSystemInIncognito(); |
| 677 } | 682 } |
| 678 #endif | 683 #endif |
| 679 } | 684 } |
| 680 | 685 |
| 681 } // namespace extensions | 686 } // namespace extensions |
| OLD | NEW |