| OLD | NEW |
| 1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 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 "extensions/common/extension.h" | 5 #include "extensions/common/extension.h" |
| 6 | 6 |
| 7 #include <stddef.h> | 7 #include <stddef.h> |
| 8 | 8 |
| 9 #include <algorithm> | 9 #include <algorithm> |
| 10 #include <utility> | 10 #include <utility> |
| (...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 69 // Extensions are cross-platform. | 69 // Extensions are cross-platform. |
| 70 // Since FilePath uses backslash '\\' as file path separator on Windows, so we | 70 // Since FilePath uses backslash '\\' as file path separator on Windows, so we |
| 71 // need to check manually. | 71 // need to check manually. |
| 72 if (path.value().find('\\') != path.value().npos) | 72 if (path.value().find('\\') != path.value().npos) |
| 73 return true; | 73 return true; |
| 74 return !net::IsSafePortableRelativePath(path); | 74 return !net::IsSafePortableRelativePath(path); |
| 75 } | 75 } |
| 76 | 76 |
| 77 } // namespace | 77 } // namespace |
| 78 | 78 |
| 79 const int Extension::kInitFromValueFlagBits = 13; | 79 const int Extension::kInitFromValueFlagBits = 14; |
| 80 | 80 |
| 81 const char Extension::kMimeType[] = "application/x-chrome-extension"; | 81 const char Extension::kMimeType[] = "application/x-chrome-extension"; |
| 82 | 82 |
| 83 const int Extension::kValidWebExtentSchemes = | 83 const int Extension::kValidWebExtentSchemes = |
| 84 URLPattern::SCHEME_HTTP | URLPattern::SCHEME_HTTPS; | 84 URLPattern::SCHEME_HTTP | URLPattern::SCHEME_HTTPS; |
| 85 | 85 |
| 86 const int Extension::kValidBookmarkAppSchemes = URLPattern::SCHEME_HTTP | | 86 const int Extension::kValidBookmarkAppSchemes = URLPattern::SCHEME_HTTP | |
| 87 URLPattern::SCHEME_HTTPS | | 87 URLPattern::SCHEME_HTTPS | |
| 88 URLPattern::SCHEME_EXTENSION; | 88 URLPattern::SCHEME_EXTENSION; |
| 89 | 89 |
| (...skipping 678 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 768 from_ephemeral(from_ephemeral), | 768 from_ephemeral(from_ephemeral), |
| 769 old_name(old_name) {} | 769 old_name(old_name) {} |
| 770 | 770 |
| 771 UpdatedExtensionPermissionsInfo::UpdatedExtensionPermissionsInfo( | 771 UpdatedExtensionPermissionsInfo::UpdatedExtensionPermissionsInfo( |
| 772 const Extension* extension, | 772 const Extension* extension, |
| 773 const PermissionSet& permissions, | 773 const PermissionSet& permissions, |
| 774 Reason reason) | 774 Reason reason) |
| 775 : reason(reason), extension(extension), permissions(permissions) {} | 775 : reason(reason), extension(extension), permissions(permissions) {} |
| 776 | 776 |
| 777 } // namespace extensions | 777 } // namespace extensions |
| OLD | NEW |