Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(492)

Unified Diff: extensions/common/user_script.h

Issue 348313003: Create withheld permissions (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Latest master Created 6 years, 5 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 | « extensions/common/url_pattern.cc ('k') | extensions/renderer/dispatcher.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: extensions/common/user_script.h
diff --git a/extensions/common/user_script.h b/extensions/common/user_script.h
index 9165e621865397f2aceb8cd9ba889a64133f5e61..54f5879e5bdf1bdd25d62c8bda55d51c854b4276 100644
--- a/extensions/common/user_script.h
+++ b/extensions/common/user_script.h
@@ -35,6 +35,19 @@ class UserScript {
// canExecuteScriptEverywhere is true, this will return ALL_SCHEMES.
static int ValidUserScriptSchemes(bool canExecuteScriptEverywhere = false);
+ // TODO(rdevlin.cronin) This and RunLocataion don't really belong here, since
+ // they are used for more than UserScripts (e.g., tabs.executeScript()).
+ // The type of injected script.
+ enum InjectionType {
+ // A content script specified in the extension's manifest.
+ CONTENT_SCRIPT,
+ // A script injected via, e.g. tabs.executeScript().
+ PROGRAMMATIC_SCRIPT
+ };
+ // The last type of injected script; used for enum verification in IPC.
+ // Update this if you add more injected script types!
+ static const InjectionType INJECTION_TYPE_LAST = PROGRAMMATIC_SCRIPT;
+
// Locations that user scripts can be run inside the document.
enum RunLocation {
UNDEFINED,
« no previous file with comments | « extensions/common/url_pattern.cc ('k') | extensions/renderer/dispatcher.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698