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

Side by Side 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: . Created 8 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 [ 5 [
6 { 6 {
7 "namespace": "tabs", 7 "namespace": "tabs",
8 "dependencies": [ "extension", "windows" ], 8 "dependencies": [ "extension", "windows" ],
9 "types": [ 9 "types": [
10 { 10 {
11 "id": "Tab", 11 "id": "Tab",
12 "type": "object", 12 "type": "object",
13 "properties": { 13 "properties": {
14 "id": {"type": "integer", "minimum": 0, "description": "The ID of the tab. Tab IDs are unique within a browser session."}, 14 "id": {"type": "integer", "minimum": 0, "description": "The ID of the tab. Tab IDs are unique within a browser session."},
15 "index": {"type": "integer", "minimum": 0, "description": "The zero-ba sed index of the tab within its window."}, 15 "index": {"type": "integer", "minimum": 0, "description": "The zero-ba sed index of the tab within its window."},
16 "windowId": {"type": "integer", "minimum": 0, "description": "The ID o f the window the tab is contained within."}, 16 "windowId": {"type": "integer", "minimum": 0, "description": "The ID o f the window the tab is contained within."},
17 "openerTabId": {"type": "integer", "minimum": 0, "optional": true, "de scription": "The ID of the tab that opened this tab, if any. This will only be p resent if the opener tab still exists."}, 17 "openerTabId": {"type": "integer", "minimum": 0, "optional": true, "de scription": "The ID of the tab that opened this tab, if any. This will only be p resent if the opener tab still exists."},
18 "selected": {"type": "boolean", "description": "Whether the tab is sel ected.", "nodoc": true}, 18 "selected": {"type": "boolean", "description": "Whether the tab is sel ected.", "nodoc": true},
19 "highlighted": {"type": "boolean", "description": "Whether the tab is highlighted."}, 19 "highlighted": {"type": "boolean", "description": "Whether the tab is highlighted."},
20 "active": {"type": "boolean", "description": "Whether the tab is activ e in its window."}, 20 "active": {"type": "boolean", "description": "Whether the tab is activ e in its window."},
21 "pinned": {"type": "boolean", "description": "Whether the tab is pinne d."}, 21 "pinned": {"type": "boolean", "description": "Whether the tab is pinne d."},
22 "url": {"type": "string", "description": "The URL the tab is displayin g."}, 22 "url": {"type": "string", "description": "The URL the tab is displayin g."},
23 "title": {"type": "string", "optional": true, "description": "The titl e of the tab. This may not be available if the tab is loading."}, 23 "title": {"type": "string", "optional": true, "description": "The titl e of the tab. This may not be available if the tab is loading."},
24 "favIconUrl": {"type": "string", "optional": true, "description": "The URL of the tab's favicon. This may not be available if the tab is loading."}, 24 "favIconUrl": {"type": "string", "optional": true, "description": "The URL of the tab's favicon. This may not be available if the tab is loading."},
25 "status": {"type": "string", "optional": true, "description": "Either <em>loading</em> or <em>complete</em>."}, 25 "status": {"type": "string", "optional": true, "description": "Either <em>loading</em> or <em>complete</em>."},
26 "incognito": {"type": "boolean", "description": "Whether the tab is in an incognito window."} 26 "incognito": {"type": "boolean", "description": "Whether the tab is in an incognito window."}
27 } 27 }
28 },
29 {
30 "id": "InjectDetails",
31 "type": "object",
32 "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.",
33 "properties": {
34 "code": {"type": "string", "optional": true, "description": "JavaScrip t or CSS code to execute."},
35 "file": {"type": "string", "optional": true, "description": "JavaScrip t or CSS file to execute."},
36 "allFrames": {"type": "boolean", "optional": true, "description": "If allFrames is true, this function injects the script into all frames of current p age. By default, it's false and the script is injected only into the top main fr ame."},
37 "runAt": {
38 "type": "string",
39 "optional": true,
40 "enum": ["document_start", "document_end", "document_idle"],
41 "description": "The soonest that the script will be injected into th e tab. Defaults to \"document_idle\"."
42 }
43 }
28 } 44 }
29 ], 45 ],
30 "functions": [ 46 "functions": [
31 { 47 {
32 "name": "get", 48 "name": "get",
33 "type": "function", 49 "type": "function",
34 "description": "Retrieves details about the specified tab.", 50 "description": "Retrieves details about the specified tab.",
35 "parameters": [ 51 "parameters": [
36 { 52 {
37 "type": "integer", 53 "type": "integer",
(...skipping 555 matching lines...) Expand 10 before | Expand all | Expand 10 after
593 } 609 }
594 ] 610 ]
595 }, 611 },
596 { 612 {
597 "name": "executeScript", 613 "name": "executeScript",
598 "type": "function", 614 "type": "function",
599 "description": "Injects JavaScript code into a page. For details, see th e <a href='content_scripts.html#pi'>programmatic injection</a> section of the co ntent scripts doc.", 615 "description": "Injects JavaScript code into a page. For details, see th e <a href='content_scripts.html#pi'>programmatic injection</a> section of the co ntent scripts doc.",
600 "parameters": [ 616 "parameters": [
601 {"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."}, 617 {"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."},
602 { 618 {
603 "type": "object", 619 "$ref": "tabs.InjectDetails",
604 "name": "details", 620 "name": "details",
605 "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.", 621 "description": "Details of the script to run."
606 "properties": {
607 "code": {"type": "string", "optional": true, "description": "JavaS cript code to execute."},
608 "file": {"type": "string", "optional": true, "description": "JavaS cript file to execute."},
609 "allFrames": {"type": "boolean", "optional": true, "description": "If allFrames is true, this function injects script into all frames of current p age. By default, it's false and script is injected only into the top main frame. "},
610 "runAt": {
611 "type": "string",
612 "optional": true,
613 "enum": ["document_start", "document_end", "document_idle"],
614 "description": "The soonest that the script will be injected int o the tab. Defaults to \"document_idle\"."
615 }
616 }
617 }, 622 },
618 { 623 {
619 "type": "function", 624 "type": "function",
620 "name": "callback", 625 "name": "callback",
621 "optional": true, 626 "optional": true,
622 "description": "Called after all the JavaScript has been executed.", 627 "description": "Called after all the JavaScript has been executed.",
623 "parameters": [ 628 "parameters": [
624 { 629 {
625 "name": "result", 630 "name": "result",
626 "optional": true, 631 "optional": true,
627 "type": "array", 632 "type": "array",
628 "items": {"type": "any", "minimum": 0}, 633 "items": {"type": "any", "minimum": 0},
629 "description": "The result of the script in every injected frame ." 634 "description": "The result of the script in every injected frame ."
630 } 635 }
631 ] 636 ]
632 } 637 }
633 ] 638 ]
634 }, 639 },
635 { 640 {
636 "name": "insertCSS", 641 "name": "insertCSS",
637 "type": "function", 642 "type": "function",
638 "description": "Injects CSS into a page. For details, see the <a href='c ontent_scripts.html#pi'>programmatic injection</a> section of the content script s doc.", 643 "description": "Injects CSS into a page. For details, see the <a href='c ontent_scripts.html#pi'>programmatic injection</a> section of the content script s doc.",
639 "parameters": [ 644 "parameters": [
640 {"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."}, 645 {"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."},
641 { 646 {
642 "type": "object", 647 "$ref": "tabs.InjectDetails",
643 "name": "details", 648 "name": "details",
644 "description": "Details of the CSS text to insert. Either the code o r the file property must be set, but both may not be set at the same time.", 649 "description": "Details of the CSS text to insert."
645 "properties": {
646 "code": {"type": "string", "optional": true, "description": "CSS c ode to be injected."},
647 "file": {"type": "string", "optional": true, "description": "CSS f ile to be injected."},
648 "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." },
649 "runAt": {
650 "type": "string",
651 "optional": true,
652 "enum": ["document_start", "document_end", "document_idle"],
653 "description": "The soonest that the CSS will be injected into t he tab. Defaults to \"document_idle\"."
654 }
655 }
656 }, 650 },
657 { 651 {
658 "type": "function", 652 "type": "function",
659 "name": "callback", 653 "name": "callback",
660 "optional": true, 654 "optional": true,
661 "description": "Called when all the CSS has been inserted.", 655 "description": "Called when all the CSS has been inserted.",
662 "parameters": [] 656 "parameters": []
663 } 657 }
664 ] 658 ]
665 } 659 }
(...skipping 228 matching lines...) Expand 10 before | Expand all | Expand 10 after
894 "name": "removeInfo", 888 "name": "removeInfo",
895 "properties": { 889 "properties": {
896 "isWindowClosing": {"type": "boolean", "description": "True when t he tab is being closed because its window is being closed." } 890 "isWindowClosing": {"type": "boolean", "description": "True when t he tab is being closed because its window is being closed." }
897 } 891 }
898 } 892 }
899 ] 893 ]
900 } 894 }
901 ] 895 ]
902 } 896 }
903 ] 897 ]
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698