| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 "extensions/common/manifest_handlers/content_capabilities_handler.h" | 5 #include "extensions/common/manifest_handlers/content_capabilities_handler.h" |
| 6 | 6 |
| 7 #include "base/command_line.h" | 7 #include "base/command_line.h" |
| 8 #include "base/lazy_instance.h" | 8 #include "base/lazy_instance.h" |
| 9 #include "base/memory/scoped_ptr.h" | 9 #include "base/memory/scoped_ptr.h" |
| 10 #include "base/strings/string_number_conversions.h" | 10 #include "base/strings/string_number_conversions.h" |
| 11 #include "base/strings/utf_string_conversions.h" | 11 #include "base/strings/utf_string_conversions.h" |
| 12 #include "base/values.h" | 12 #include "base/values.h" |
| 13 #include "content/public/common/content_switches.h" | 13 #include "content/public/common/content_switches.h" |
| 14 #include "extensions/common/api/extensions_manifest_types.h" | 14 #include "extensions/common/api/extensions_manifest_types.h" |
| 15 #include "extensions/common/error_utils.h" | 15 #include "extensions/common/error_utils.h" |
| 16 #include "extensions/common/install_warning.h" | 16 #include "extensions/common/install_warning.h" |
| 17 #include "extensions/common/manifest_constants.h" | 17 #include "extensions/common/manifest_constants.h" |
| 18 #include "extensions/common/permissions/permissions_info.h" | 18 #include "extensions/common/permissions/permissions_info.h" |
| 19 #include "extensions/common/url_pattern.h" | 19 #include "extensions/common/url_pattern.h" |
| 20 | 20 |
| 21 namespace extensions { | 21 namespace extensions { |
| 22 | 22 |
| 23 namespace keys = manifest_keys; | 23 namespace keys = manifest_keys; |
| 24 namespace errors = manifest_errors; | 24 namespace errors = manifest_errors; |
| 25 | 25 |
| 26 using core_api::extensions_manifest_types::ContentCapabilities; | 26 using api::extensions_manifest_types::ContentCapabilities; |
| 27 | 27 |
| 28 ContentCapabilitiesInfo::ContentCapabilitiesInfo() { | 28 ContentCapabilitiesInfo::ContentCapabilitiesInfo() { |
| 29 } | 29 } |
| 30 | 30 |
| 31 ContentCapabilitiesInfo::~ContentCapabilitiesInfo() { | 31 ContentCapabilitiesInfo::~ContentCapabilitiesInfo() { |
| 32 } | 32 } |
| 33 | 33 |
| 34 static base::LazyInstance<ContentCapabilitiesInfo> | 34 static base::LazyInstance<ContentCapabilitiesInfo> |
| 35 g_empty_content_capabilities_info = LAZY_INSTANCE_INITIALIZER; | 35 g_empty_content_capabilities_info = LAZY_INSTANCE_INITIALIZER; |
| 36 | 36 |
| (...skipping 71 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 108 extension->SetManifestData(keys::kContentCapabilities, info.release()); | 108 extension->SetManifestData(keys::kContentCapabilities, info.release()); |
| 109 return true; | 109 return true; |
| 110 } | 110 } |
| 111 | 111 |
| 112 const std::vector<std::string> ContentCapabilitiesHandler::Keys() | 112 const std::vector<std::string> ContentCapabilitiesHandler::Keys() |
| 113 const { | 113 const { |
| 114 return SingleKey(keys::kContentCapabilities); | 114 return SingleKey(keys::kContentCapabilities); |
| 115 } | 115 } |
| 116 | 116 |
| 117 } // namespace extensions | 117 } // namespace extensions |
| OLD | NEW |