| 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/common/extensions/extension.h" | 5 #include "chrome/common/extensions/extension.h" |
| 6 | 6 |
| 7 #include <ostream> | 7 #include <ostream> |
| 8 | 8 |
| 9 #include "base/base64.h" | 9 #include "base/base64.h" |
| 10 #include "base/basictypes.h" | 10 #include "base/basictypes.h" |
| (...skipping 3095 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3106 APIPermissionSet api_permissions; | 3106 APIPermissionSet api_permissions; |
| 3107 URLPatternSet host_permissions; | 3107 URLPatternSet host_permissions; |
| 3108 if (!ParsePermissions(keys::kPermissions, | 3108 if (!ParsePermissions(keys::kPermissions, |
| 3109 error, | 3109 error, |
| 3110 &api_permissions, | 3110 &api_permissions, |
| 3111 &host_permissions)) { | 3111 &host_permissions)) { |
| 3112 return false; | 3112 return false; |
| 3113 } | 3113 } |
| 3114 | 3114 |
| 3115 // TODO(jeremya/kalman) do this via the features system by exposing the | 3115 // TODO(jeremya/kalman) do this via the features system by exposing the |
| 3116 // appWindow API to platform apps, with no dependency on any permissions. | 3116 // app.window API to platform apps, with no dependency on any permissions. |
| 3117 // See http://crbug.com/120069. | 3117 // See http://crbug.com/120069. |
| 3118 if (is_platform_app()) | 3118 if (is_platform_app()) |
| 3119 api_permissions.insert(APIPermission::kAppWindow); | 3119 api_permissions.insert(APIPermission::kAppWindow); |
| 3120 | 3120 |
| 3121 APIPermissionSet optional_api_permissions; | 3121 APIPermissionSet optional_api_permissions; |
| 3122 URLPatternSet optional_host_permissions; | 3122 URLPatternSet optional_host_permissions; |
| 3123 if (!ParsePermissions(keys::kOptionalPermissions, | 3123 if (!ParsePermissions(keys::kOptionalPermissions, |
| 3124 error, | 3124 error, |
| 3125 &optional_api_permissions, | 3125 &optional_api_permissions, |
| 3126 &optional_host_permissions)) { | 3126 &optional_host_permissions)) { |
| (...skipping 743 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3870 | 3870 |
| 3871 UpdatedExtensionPermissionsInfo::UpdatedExtensionPermissionsInfo( | 3871 UpdatedExtensionPermissionsInfo::UpdatedExtensionPermissionsInfo( |
| 3872 const Extension* extension, | 3872 const Extension* extension, |
| 3873 const PermissionSet* permissions, | 3873 const PermissionSet* permissions, |
| 3874 Reason reason) | 3874 Reason reason) |
| 3875 : reason(reason), | 3875 : reason(reason), |
| 3876 extension(extension), | 3876 extension(extension), |
| 3877 permissions(permissions) {} | 3877 permissions(permissions) {} |
| 3878 | 3878 |
| 3879 } // namespace extensions | 3879 } // namespace extensions |
| OLD | NEW |