Chromium Code Reviews
[email protected] (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(752)

Unified Diff: chrome/common/extensions/extension.h

Issue 3263007: Reland r57788 - Expose Extension Bindings to Component Applications (Closed) Base URL: http://src.chromium.org/git/chromium.git
Patch Set: don't hide gallery url in omnibar Created 10 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/browser/tab_contents/tab_contents_view.cc ('k') | chrome/common/extensions/extension.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/common/extensions/extension.h
diff --git a/chrome/common/extensions/extension.h b/chrome/common/extensions/extension.h
index 9f2dc9ba2c6f0594bd5c9449b5a66da5dedc5a31..66e12f2170ffeb4ce11fbc51d75d7b2bdd384c64 100644
--- a/chrome/common/extensions/extension.h
+++ b/chrome/common/extensions/extension.h
@@ -278,9 +278,11 @@ class Extension {
}
// Returns true if the extension has the specified API permission.
+ static bool HasApiPermission(const std::vector<std::string>& api_permissions,
+ const std::string& permission);
+
bool HasApiPermission(const std::string& permission) const {
- return std::find(api_permissions_.begin(), api_permissions_.end(),
- permission) != api_permissions_.end();
+ return HasApiPermission(this->api_permissions(), permission);
}
// Returns the set of hosts that the extension effectively has access to. This
« no previous file with comments | « chrome/browser/tab_contents/tab_contents_view.cc ('k') | chrome/common/extensions/extension.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698