| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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_extensions_whitelist/whitelist.h" | 5 #include "chrome/browser/extensions/component_extensions_whitelist/whitelist.h" |
| 6 | 6 |
| 7 #include <stddef.h> | 7 #include <stddef.h> |
| 8 | 8 |
| 9 #include "base/logging.h" | 9 #include "base/logging.h" |
| 10 #include "base/macros.h" | 10 #include "base/macros.h" |
| (...skipping 22 matching lines...) Expand all Loading... |
| 33 extension_misc::kHotwordSharedModuleId, | 33 extension_misc::kHotwordSharedModuleId, |
| 34 extension_misc::kInAppPaymentsSupportAppId, | 34 extension_misc::kInAppPaymentsSupportAppId, |
| 35 #if defined(ENABLE_MEDIA_ROUTER) | 35 #if defined(ENABLE_MEDIA_ROUTER) |
| 36 extension_misc::kMediaRouterStableExtensionId, | 36 extension_misc::kMediaRouterStableExtensionId, |
| 37 #endif // defined(ENABLE_MEDIA_ROUTER) | 37 #endif // defined(ENABLE_MEDIA_ROUTER) |
| 38 extension_misc::kPdfExtensionId, | 38 extension_misc::kPdfExtensionId, |
| 39 #if defined(OS_CHROMEOS) | 39 #if defined(OS_CHROMEOS) |
| 40 extension_misc::kChromeVoxExtensionId, | 40 extension_misc::kChromeVoxExtensionId, |
| 41 extension_misc::kSelectToSpeakExtensionId, | 41 extension_misc::kSelectToSpeakExtensionId, |
| 42 extension_misc::kSpeechSynthesisExtensionId, | 42 extension_misc::kSpeechSynthesisExtensionId, |
| 43 extension_misc::kSwitchAccessExtensionId, |
| 43 extension_misc::kZIPUnpackerExtensionId, | 44 extension_misc::kZIPUnpackerExtensionId, |
| 44 #endif | 45 #endif |
| 45 }; | 46 }; |
| 46 | 47 |
| 47 for (size_t i = 0; i < arraysize(kAllowed); ++i) { | 48 for (size_t i = 0; i < arraysize(kAllowed); ++i) { |
| 48 if (extension_id == kAllowed[i]) | 49 if (extension_id == kAllowed[i]) |
| 49 return true; | 50 return true; |
| 50 } | 51 } |
| 51 | 52 |
| 52 #if BUILDFLAG(ENABLE_APP_LIST) && defined(OS_CHROMEOS) | 53 #if BUILDFLAG(ENABLE_APP_LIST) && defined(OS_CHROMEOS) |
| (...skipping 75 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 128 } | 129 } |
| 129 | 130 |
| 130 LOG(ERROR) << "Component extension with manifest resource id " | 131 LOG(ERROR) << "Component extension with manifest resource id " |
| 131 << manifest_resource_id << " not in whitelist and is not being " | 132 << manifest_resource_id << " not in whitelist and is not being " |
| 132 << "loaded as a result."; | 133 << "loaded as a result."; |
| 133 NOTREACHED(); | 134 NOTREACHED(); |
| 134 return false; | 135 return false; |
| 135 } | 136 } |
| 136 | 137 |
| 137 } // namespace extensions | 138 } // namespace extensions |
| OLD | NEW |