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

Side by Side Diff: chrome/common/extensions/api/tabs.json

Issue 2153943002: Implementing TabManager extensions API Discard Function. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fixing comments Created 4 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 unified diff | Download patch
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 "description": "Use the <code>chrome.tabs</code> API to interact with the br owser's tab system. You can use this API to create, modify, and rearrange tabs i n the browser.", 8 "description": "Use the <code>chrome.tabs</code> API to interact with the br owser's tab system. You can use this API to create, modify, and rearrange tabs i n the browser.",
9 "types": [ 9 "types": [
10 { "id": "MutedInfoReason", 10 { "id": "MutedInfoReason",
(...skipping 889 matching lines...) Expand 10 before | Expand all | Expand 10 after
900 "description": "Called with the tab's current zoom settings.", 900 "description": "Called with the tab's current zoom settings.",
901 "parameters": [ 901 "parameters": [
902 { 902 {
903 "$ref": "ZoomSettings", 903 "$ref": "ZoomSettings",
904 "name": "zoomSettings", 904 "name": "zoomSettings",
905 "description": "The tab's current zoom settings." 905 "description": "The tab's current zoom settings."
906 } 906 }
907 ] 907 ]
908 } 908 }
909 ] 909 ]
910 },
911 {
912 "name": "discard",
913 "type": "function",
914 "description": "Discards a tab from memory. Discarded tabs are still vis ible on the tab strip and get reloaded when activated.",
Devlin 2016/07/21 15:39:21 nit: s/get reloaded/are reloaded I also wonder if
Anderson Silva 2016/07/21 20:43:04 Reloaded is what we've always been using, so we ar
Georges Khalil 2016/07/21 21:02:23 We can definitely revisit the "reload" terminology
915 "parameters": [
916 {
917 "type": "integer",
918 "name": "tabId",
919 "optional": true,
920 "minimum": 0,
921 "description": "The ID of the tab to be discarded; defaults to the l east important tab."
922 },
923 {
924 "type": "function",
925 "name": "callback",
926 "optional": true,
927 "description": "Called after the operation is completed.",
928 "parameters": [
929 {
930 "name": "tab",
931 "$ref": "Tab",
932 "description": "Discarded tab if it was successfully discarded."
Devlin 2016/07/21 15:39:21 Tying into the comment in the api.cc file, could t
Anderson Silva 2016/07/21 20:43:04 Solved by removing the boolean and by returning un
933 },
934 {
935 "name": "success",
936 "type": "boolean",
937 "description": "Status describing if the tab was successfully di scarded or not."
938 }
939 ]
940 }
941 ]
910 } 942 }
911 ], 943 ],
912 "events": [ 944 "events": [
913 { 945 {
914 "name": "onCreated", 946 "name": "onCreated",
915 "type": "function", 947 "type": "function",
916 "description": "Fired when a tab is created. Note that the tab's URL may not be set at the time this event fired, but you can listen to onUpdated events to be notified when a URL is set.", 948 "description": "Fired when a tab is created. Note that the tab's URL may not be set at the time this event fired, but you can listen to onUpdated events to be notified when a URL is set.",
917 "parameters": [ 949 "parameters": [
918 { 950 {
919 "$ref": "Tab", 951 "$ref": "Tab",
(...skipping 264 matching lines...) Expand 10 before | Expand all | Expand 10 after
1184 "tabId": {"type": "integer", "minimum": 0}, 1216 "tabId": {"type": "integer", "minimum": 0},
1185 "oldZoomFactor": {"type": "number"}, 1217 "oldZoomFactor": {"type": "number"},
1186 "newZoomFactor": {"type": "number"}, 1218 "newZoomFactor": {"type": "number"},
1187 "zoomSettings": {"$ref": "ZoomSettings"} 1219 "zoomSettings": {"$ref": "ZoomSettings"}
1188 } 1220 }
1189 }] 1221 }]
1190 } 1222 }
1191 ] 1223 ]
1192 } 1224 }
1193 ] 1225 ]
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698