Chromium Code Reviews| Index: extensions/common/permissions/api_permission.h |
| diff --git a/extensions/common/permissions/api_permission.h b/extensions/common/permissions/api_permission.h |
| index 28b7c97fdafbad59c32347dd6aef1086409034d2..444184af4a2a53b97747b06f37139c80df85cdf3 100644 |
| --- a/extensions/common/permissions/api_permission.h |
| +++ b/extensions/common/permissions/api_permission.h |
| @@ -34,14 +34,17 @@ class APIPermission { |
| // The IDs of all permissions available to apps. Add as many permissions here |
| // as needed to generate meaningful permission messages. Add the rules for the |
| // messages to ChromePermissionMessageProvider. |
| - // Remove permissions from this list if they have no longer have a |
| - // corresponding API permission and no permission message. |
| + // Do not reorder this enumeration or remove any entries. If you need to add a |
| + // new entry, add it just prior to kEnumBoundary. |
| // TODO(sashab): Move this to a more central location, and rename it to |
| // PermissionID. |
| enum ID { |
| // Error codes. |
| - kInvalid = -2, |
| - kUnknown = -1, |
| + kInvalid, |
| + kUnknown, |
| + |
| + // For use in histograms. |
| + kNone, |
|
Marc Treib
2015/04/17 13:09:33
Not quite sure about this: The existing histograms
Devlin
2015/04/27 17:58:03
I agree - it's weird to have "None" as a unique pe
Marc Treib
2015/04/28 12:31:32
I've removed the "None" type for the new histogram
|
| // Real permissions. |
| kAccessibilityFeaturesModify, |
| @@ -237,6 +240,9 @@ class APIPermission { |
| kUsbDeviceUnknownProduct, |
| kUsbDeviceUnknownVendor, |
| + // Last entry: Add new entries above and ensure to update the |
| + // "ExtensionPermission3" enum in tools/metrics/histograms/histograms.xml |
| + // (by running update_extension_functions.py). |
| kEnumBoundary |
| }; |