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

Unified Diff: chrome/common/extensions/api/tabs.json

Issue 10815028: Make ActiveTabPermissionManager also grant the tabs permission. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: oops Created 8 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 | « chrome/chrome_tests.gypi ('k') | chrome/common/extensions/docs/extensions/tabs.html » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/common/extensions/api/tabs.json
diff --git a/chrome/common/extensions/api/tabs.json b/chrome/common/extensions/api/tabs.json
index ccf137aef024ada0304f2e4e8785d0a7d4531227..537e11a61676c267cb27456e04b3dd8d3faf7b59 100644
--- a/chrome/common/extensions/api/tabs.json
+++ b/chrome/common/extensions/api/tabs.json
@@ -25,6 +25,22 @@
"status": {"type": "string", "optional": true, "description": "Either <em>loading</em> or <em>complete</em>."},
"incognito": {"type": "boolean", "description": "Whether the tab is in an incognito window."}
}
+ },
+ {
+ "id": "InjectDetails",
+ "type": "object",
+ "description": "Details of the script or CSS to inject. Either the code or the file property must be set, but both may not be set at the same time.",
+ "properties": {
+ "code": {"type": "string", "optional": true, "description": "JavaScript or CSS code to inject."},
+ "file": {"type": "string", "optional": true, "description": "JavaScript or CSS file to inject."},
+ "allFrames": {"type": "boolean", "optional": true, "description": "If allFrames is <code>true</code>, implies that the JavaScript or CSS should be injected into all frames of current page. By default, it's <code>false</code> and will only be injected into the top frame."},
+ "runAt": {
+ "type": "string",
+ "optional": true,
+ "enum": ["document_start", "document_end", "document_idle"],
+ "description": "The soonest that the JavaScript or CSS will be injected into the tab. Defaults to \"document_idle\"."
+ }
+ }
}
],
"functions": [
@@ -600,20 +616,9 @@
"parameters": [
{"type": "integer", "name": "tabId", "optional": true, "description": "The ID of the tab in which to run the script; defaults to the active tab of the current window."},
{
- "type": "object",
+ "$ref": "tabs.InjectDetails",
"name": "details",
- "description": "Details of the script to run. Either the code or the file property must be set, but both may not be set at the same time.",
- "properties": {
- "code": {"type": "string", "optional": true, "description": "JavaScript code to execute."},
- "file": {"type": "string", "optional": true, "description": "JavaScript file to execute."},
- "allFrames": {"type": "boolean", "optional": true, "description": "If allFrames is true, this function injects script into all frames of current page. By default, it's false and script is injected only into the top main frame."},
- "runAt": {
- "type": "string",
- "optional": true,
- "enum": ["document_start", "document_end", "document_idle"],
- "description": "The soonest that the script will be injected into the tab. Defaults to \"document_idle\"."
- }
- }
+ "description": "Details of the script to run."
},
{
"type": "function",
@@ -639,20 +644,9 @@
"parameters": [
{"type": "integer", "name": "tabId", "optional": true, "description": "The ID of the tab in which to insert the CSS; defaults to the active tab of the current window."},
{
- "type": "object",
+ "$ref": "tabs.InjectDetails",
"name": "details",
- "description": "Details of the CSS text to insert. Either the code or the file property must be set, but both may not be set at the same time.",
- "properties": {
- "code": {"type": "string", "optional": true, "description": "CSS code to be injected."},
- "file": {"type": "string", "optional": true, "description": "CSS file to be injected."},
- "allFrames": {"type": "boolean", "optional": true, "description": "If allFrames is true, this function injects CSS text into all frames of current page. By default, it's false and CSS is injected only into the top main frame."},
- "runAt": {
- "type": "string",
- "optional": true,
- "enum": ["document_start", "document_end", "document_idle"],
- "description": "The soonest that the CSS will be injected into the tab. Defaults to \"document_idle\"."
- }
- }
+ "description": "Details of the CSS text to insert."
},
{
"type": "function",
« no previous file with comments | « chrome/chrome_tests.gypi ('k') | chrome/common/extensions/docs/extensions/tabs.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698