diff options
author | kalman@chromium.org <kalman@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2012-05-24 07:18:42 +0000 |
---|---|---|
committer | kalman@chromium.org <kalman@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2012-05-24 07:18:42 +0000 |
commit | f3b25bf85396e81487f4af43da9b332960c854e4 (patch) | |
tree | 060cab069499e62cf172a875f84cfc30b4278798 | |
parent | 7d78be1dc97de1c4378112ea0610b46f3645dcf5 (diff) | |
download | chromium_src-f3b25bf85396e81487f4af43da9b332960c854e4.zip chromium_src-f3b25bf85396e81487f4af43da9b332960c854e4.tar.gz chromium_src-f3b25bf85396e81487f4af43da9b332960c854e4.tar.bz2 |
Add the "activeTab" permission and feature (nothing uses them yet).
BUG=93903
Review URL: https://chromiumcodereview.appspot.com/10414071
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@138747 0039d316-1c4b-4281-b951-d872f2087c98
4 files changed, 10 insertions, 0 deletions
diff --git a/chrome/common/extensions/api/_permission_features.json b/chrome/common/extensions/api/_permission_features.json index 834b60a..2301b91 100644 --- a/chrome/common/extensions/api/_permission_features.json +++ b/chrome/common/extensions/api/_permission_features.json @@ -3,6 +3,11 @@ // found in the LICENSE file. { + "activeTab": { + "channel": "dev", + "extension_types": ["extension", "packaged_app"], + "min_manifest_version": 2 + }, "alarms": { "channel": "dev", "extension_types": ["extension", "packaged_app", "platform_app"], diff --git a/chrome/common/extensions/extension_permission_set.cc b/chrome/common/extensions/extension_permission_set.cc index 027e342..6718a98 100644 --- a/chrome/common/extensions/extension_permission_set.cc +++ b/chrome/common/extensions/extension_permission_set.cc @@ -213,6 +213,9 @@ void ExtensionAPIPermission::RegisterAllPermissions( // Register extension permissions. info->RegisterPermission( + kActiveTab, "activeTab", 0, + ExtensionPermissionMessage::kNone, kFlagNone); + info->RegisterPermission( kAlarms, "alarms", 0, ExtensionPermissionMessage::kNone, kFlagNone); info->RegisterPermission( diff --git a/chrome/common/extensions/extension_permission_set.h b/chrome/common/extensions/extension_permission_set.h index 10a7ee4..5e1c9cb 100644 --- a/chrome/common/extensions/extension_permission_set.h +++ b/chrome/common/extensions/extension_permission_set.h @@ -97,6 +97,7 @@ class ExtensionAPIPermission { kUnknown = -1, // Real permissions. + kActiveTab, kAlarms, kAppNotifications, kBackground, diff --git a/chrome/common/extensions/extension_permission_set_unittest.cc b/chrome/common/extensions/extension_permission_set_unittest.cc index 5e483e0..6efb43e 100644 --- a/chrome/common/extensions/extension_permission_set_unittest.cc +++ b/chrome/common/extensions/extension_permission_set_unittest.cc @@ -560,6 +560,7 @@ TEST(ExtensionPermissionsTest, PermissionMessages) { // These are considered "nuisance" or "trivial" permissions that don't need // a prompt. + skip.insert(ExtensionAPIPermission::kActiveTab); skip.insert(ExtensionAPIPermission::kAlarms); skip.insert(ExtensionAPIPermission::kAppNotifications); skip.insert(ExtensionAPIPermission::kBrowsingData); |