OLD | NEW |
1 // Copyright 2017 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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 // This file was generated by: | 5 // This file was generated by: |
6 // tools/json_schema_compiler/compiler.py. | 6 // tools/json_schema_compiler/compiler.py -g externs |
7 // NOTE: The format of types has changed. 'FooType' is now | 7 // chrome/common/extensions/api/automation.idl |
8 // 'chrome.automation.FooType'. | 8 // |
9 // Please run the closure compiler before committing changes. | 9 // Further edits were applied by hand due to bugs / limitations in |
| 10 // json_schema_compiler. |
| 11 // |
10 // See https://chromium.googlesource.com/chromium/src/+/master/docs/closure_comp
ilation.md | 12 // See https://chromium.googlesource.com/chromium/src/+/master/docs/closure_comp
ilation.md |
11 | 13 |
12 /** @fileoverview Externs generated from namespace: automation */ | 14 /** @fileoverview Externs generated from namespace: automation */ |
13 | 15 |
14 /** | 16 /** |
15 * @const | 17 * @const |
16 */ | 18 */ |
17 chrome.automation = {}; | 19 chrome.automation = {}; |
18 | 20 |
19 /** | 21 /** |
20 * @enum {string} | 22 * @enum {string} |
21 * @see https://developer.chrome.com/extensions/automation#type-EventType | |
22 */ | 23 */ |
23 chrome.automation.EventType = { | 24 chrome.automation.EventType = { |
24 ACTIVEDESCENDANTCHANGED: 'activedescendantchanged', | 25 activedescendantchanged: '', |
25 ALERT: 'alert', | 26 alert: '', |
26 ARIA_ATTRIBUTE_CHANGED: 'ariaAttributeChanged', | 27 ariaAttributeChanged: '', |
27 AUTOCORRECTION_OCCURED: 'autocorrectionOccured', | 28 autocorrectionOccured: '', |
28 BLUR: 'blur', | 29 blur: '', |
29 CHECKED_STATE_CHANGED: 'checkedStateChanged', | 30 checkedStateChanged: '', |
30 CHILDREN_CHANGED: 'childrenChanged', | 31 childrenChanged: '', |
31 CLICKED: 'clicked', | 32 documentSelectionChanged: '', |
32 DOCUMENT_SELECTION_CHANGED: 'documentSelectionChanged', | 33 expandedChanged: '', |
33 EXPANDED_CHANGED: 'expandedChanged', | 34 focus: '', |
34 FOCUS: 'focus', | 35 hide: '', |
35 IMAGE_FRAME_UPDATED: 'imageFrameUpdated', | 36 hover: '', |
36 HIDE: 'hide', | 37 invalidStatusChanged: '', |
37 HOVER: 'hover', | 38 layoutComplete: '', |
38 INVALID_STATUS_CHANGED: 'invalidStatusChanged', | 39 liveRegionChanged: '', |
39 LAYOUT_COMPLETE: 'layoutComplete', | 40 loadComplete: '', |
40 LIVE_REGION_CREATED: 'liveRegionCreated', | 41 locationChanged: '', |
41 LIVE_REGION_CHANGED: 'liveRegionChanged', | 42 menuEnd: '', |
42 LOAD_COMPLETE: 'loadComplete', | 43 menuListItemSelected: '', |
43 LOCATION_CHANGED: 'locationChanged', | 44 menuListValueChanged: '', |
44 MEDIA_STARTED_PLAYING: 'mediaStartedPlaying', | 45 menuPopupEnd: '', |
45 MEDIA_STOPPED_PLAYING: 'mediaStoppedPlaying', | 46 menuPopupStart: '', |
46 MENU_END: 'menuEnd', | 47 menuStart: '', |
47 MENU_LIST_ITEM_SELECTED: 'menuListItemSelected', | 48 mouseCanceled: '', |
48 MENU_LIST_VALUE_CHANGED: 'menuListValueChanged', | 49 mouseDragged: '', |
49 MENU_POPUP_END: 'menuPopupEnd', | 50 mouseMoved: '', |
50 MENU_POPUP_START: 'menuPopupStart', | 51 mousePressed: '', |
51 MENU_START: 'menuStart', | 52 mouseReleased: '', |
52 MOUSE_CANCELED: 'mouseCanceled', | 53 rowCollapsed: '', |
53 MOUSE_DRAGGED: 'mouseDragged', | 54 rowCountChanged: '', |
54 MOUSE_MOVED: 'mouseMoved', | 55 rowExpanded: '', |
55 MOUSE_PRESSED: 'mousePressed', | 56 scrollPositionChanged: '', |
56 MOUSE_RELEASED: 'mouseReleased', | 57 scrolledToAnchor: '', |
57 ROW_COLLAPSED: 'rowCollapsed', | 58 selectedChildrenChanged: '', |
58 ROW_COUNT_CHANGED: 'rowCountChanged', | 59 selection: '', |
59 ROW_EXPANDED: 'rowExpanded', | 60 selectionAdd: '', |
60 SCROLL_POSITION_CHANGED: 'scrollPositionChanged', | 61 selectionRemove: '', |
61 SCROLLED_TO_ANCHOR: 'scrolledToAnchor', | 62 show: '', |
62 SELECTED_CHILDREN_CHANGED: 'selectedChildrenChanged', | 63 textChanged: '', |
63 SELECTION: 'selection', | 64 textSelectionChanged: '', |
64 SELECTION_ADD: 'selectionAdd', | 65 treeChanged: '', |
65 SELECTION_REMOVE: 'selectionRemove', | 66 valueChanged: '', |
66 SHOW: 'show', | 67 }; |
67 TEXT_CHANGED: 'textChanged', | 68 |
68 TEXT_SELECTION_CHANGED: 'textSelectionChanged', | 69 /** |
69 TREE_CHANGED: 'treeChanged', | 70 * @enum {string} |
70 VALUE_CHANGED: 'valueChanged', | |
71 }; | |
72 | |
73 /** | |
74 * @enum {string} | |
75 * @see https://developer.chrome.com/extensions/automation#type-RoleType | |
76 */ | 71 */ |
77 chrome.automation.RoleType = { | 72 chrome.automation.RoleType = { |
78 ABBR: 'abbr', | 73 alertDialog: '', |
79 ALERT_DIALOG: 'alertDialog', | 74 alert: '', |
80 ALERT: 'alert', | 75 annotation: '', |
81 ANNOTATION: 'annotation', | 76 application: '', |
82 APPLICATION: 'application', | 77 article: '', |
83 ARTICLE: 'article', | 78 banner: '', |
84 AUDIO: 'audio', | 79 blockquote: '', |
85 BANNER: 'banner', | 80 busyIndicator: '', |
86 BLOCKQUOTE: 'blockquote', | 81 button: '', |
87 BUSY_INDICATOR: 'busyIndicator', | 82 buttonDropDown: '', |
88 BUTTON: 'button', | 83 canvas: '', |
89 BUTTON_DROP_DOWN: 'buttonDropDown', | 84 caption: '', |
90 CANVAS: 'canvas', | 85 cell: '', |
91 CAPTION: 'caption', | 86 checkBox: '', |
92 CELL: 'cell', | 87 client: '', |
93 CHECK_BOX: 'checkBox', | 88 colorWell: '', |
94 CLIENT: 'client', | 89 columnHeader: '', |
95 COLOR_WELL: 'colorWell', | 90 column: '', |
96 COLUMN_HEADER: 'columnHeader', | 91 comboBox: '', |
97 COLUMN: 'column', | 92 complementary: '', |
98 COMBO_BOX: 'comboBox', | 93 contentInfo: '', |
99 COMPLEMENTARY: 'complementary', | 94 date: '', |
100 CONTENT_INFO: 'contentInfo', | 95 dateTime: '', |
101 DATE: 'date', | 96 definition: '', |
102 DATE_TIME: 'dateTime', | 97 descriptionListDetail: '', |
103 DEFINITION: 'definition', | 98 descriptionList: '', |
104 DESCRIPTION_LIST_DETAIL: 'descriptionListDetail', | 99 descriptionListTerm: '', |
105 DESCRIPTION_LIST: 'descriptionList', | 100 desktop: '', |
106 DESCRIPTION_LIST_TERM: 'descriptionListTerm', | 101 details: '', |
107 DESKTOP: 'desktop', | 102 dialog: '', |
108 DETAILS: 'details', | 103 directory: '', |
109 DIALOG: 'dialog', | 104 disclosureTriangle: '', |
110 DIRECTORY: 'directory', | 105 div: '', |
111 DISCLOSURE_TRIANGLE: 'disclosureTriangle', | 106 document: '', |
112 DIV: 'div', | 107 embeddedObject: '', |
113 DOCUMENT: 'document', | 108 figcaption: '', |
114 EMBEDDED_OBJECT: 'embeddedObject', | 109 figure: '', |
115 FEED: 'feed', | 110 footer: '', |
116 FIGCAPTION: 'figcaption', | 111 form: '', |
117 FIGURE: 'figure', | 112 grid: '', |
118 FOOTER: 'footer', | 113 group: '', |
119 FORM: 'form', | 114 heading: '', |
120 GRID: 'grid', | 115 iframe: '', |
121 GROUP: 'group', | 116 iframePresentational: '', |
122 HEADING: 'heading', | 117 ignored: '', |
123 IFRAME: 'iframe', | 118 imageMapLink: '', |
124 IFRAME_PRESENTATIONAL: 'iframePresentational', | 119 imageMap: '', |
125 IGNORED: 'ignored', | 120 image: '', |
126 IMAGE_MAP_LINK: 'imageMapLink', | 121 inlineTextBox: '', |
127 IMAGE_MAP: 'imageMap', | 122 labelText: '', |
128 IMAGE: 'image', | 123 legend: '', |
129 INLINE_TEXT_BOX: 'inlineTextBox', | 124 lineBreak: '', |
130 INPUT_TIME: 'inputTime', | 125 link: '', |
131 LABEL_TEXT: 'labelText', | 126 listBoxOption: '', |
132 LEGEND: 'legend', | 127 listBox: '', |
133 LINE_BREAK: 'lineBreak', | 128 listItem: '', |
134 LINK: 'link', | 129 listMarker: '', |
135 LIST_BOX_OPTION: 'listBoxOption', | 130 list: '', |
136 LIST_BOX: 'listBox', | 131 locationBar: '', |
137 LIST_ITEM: 'listItem', | 132 log: '', |
138 LIST_MARKER: 'listMarker', | 133 main: '', |
139 LIST: 'list', | 134 marquee: '', |
140 LOCATION_BAR: 'locationBar', | 135 math: '', |
141 LOG: 'log', | 136 menuBar: '', |
142 MAIN: 'main', | 137 menuButton: '', |
143 MARK: 'mark', | 138 menuItem: '', |
144 MARQUEE: 'marquee', | 139 menuItemCheckBox: '', |
145 MATH: 'math', | 140 menuItemRadio: '', |
146 MENU_BAR: 'menuBar', | 141 menuListOption: '', |
147 MENU_BUTTON: 'menuButton', | 142 menuListPopup: '', |
148 MENU_ITEM: 'menuItem', | 143 menu: '', |
149 MENU_ITEM_CHECK_BOX: 'menuItemCheckBox', | 144 meter: '', |
150 MENU_ITEM_RADIO: 'menuItemRadio', | 145 navigation: '', |
151 MENU_LIST_OPTION: 'menuListOption', | 146 note: '', |
152 MENU_LIST_POPUP: 'menuListPopup', | 147 outline: '', |
153 MENU: 'menu', | 148 pane: '', |
154 METER: 'meter', | 149 paragraph: '', |
155 NAVIGATION: 'navigation', | 150 popUpButton: '', |
156 NOTE: 'note', | 151 pre: '', |
157 OUTLINE: 'outline', | 152 presentational: '', |
158 PANE: 'pane', | 153 progressIndicator: '', |
159 PARAGRAPH: 'paragraph', | 154 radioButton: '', |
160 POP_UP_BUTTON: 'popUpButton', | 155 radioGroup: '', |
161 PRE: 'pre', | 156 region: '', |
162 PRESENTATIONAL: 'presentational', | 157 rootWebArea: '', |
163 PROGRESS_INDICATOR: 'progressIndicator', | 158 rowHeader: '', |
164 RADIO_BUTTON: 'radioButton', | 159 row: '', |
165 RADIO_GROUP: 'radioGroup', | 160 ruby: '', |
166 REGION: 'region', | 161 ruler: '', |
167 ROOT_WEB_AREA: 'rootWebArea', | 162 svgRoot: '', |
168 ROW_HEADER: 'rowHeader', | 163 scrollArea: '', |
169 ROW: 'row', | 164 scrollBar: '', |
170 RUBY: 'ruby', | 165 seamlessWebArea: '', |
171 RULER: 'ruler', | 166 search: '', |
172 SVG_ROOT: 'svgRoot', | 167 searchBox: '', |
173 SCROLL_AREA: 'scrollArea', | 168 slider: '', |
174 SCROLL_BAR: 'scrollBar', | 169 sliderThumb: '', |
175 SEAMLESS_WEB_AREA: 'seamlessWebArea', | 170 spinButtonPart: '', |
176 SEARCH: 'search', | 171 spinButton: '', |
177 SEARCH_BOX: 'searchBox', | 172 splitter: '', |
178 SLIDER: 'slider', | 173 staticText: '', |
179 SLIDER_THUMB: 'sliderThumb', | 174 status: '', |
180 SPIN_BUTTON_PART: 'spinButtonPart', | 175 switch: '', |
181 SPIN_BUTTON: 'spinButton', | 176 tabGroup: '', |
182 SPLITTER: 'splitter', | 177 tabList: '', |
183 STATIC_TEXT: 'staticText', | 178 tabPanel: '', |
184 STATUS: 'status', | 179 tab: '', |
185 SWITCH: 'switch', | 180 tableHeaderContainer: '', |
186 TAB_GROUP: 'tabGroup', | 181 table: '', |
187 TAB_LIST: 'tabList', | 182 textField: '', |
188 TAB_PANEL: 'tabPanel', | 183 time: '', |
189 TAB: 'tab', | 184 timer: '', |
190 TABLE_HEADER_CONTAINER: 'tableHeaderContainer', | 185 titleBar: '', |
191 TABLE: 'table', | 186 toggleButton: '', |
192 TERM: 'term', | 187 toolbar: '', |
193 TEXT_FIELD: 'textField', | 188 treeGrid: '', |
194 TIME: 'time', | 189 treeItem: '', |
195 TIMER: 'timer', | 190 tree: '', |
196 TITLE_BAR: 'titleBar', | 191 unknown: '', |
197 TOGGLE_BUTTON: 'toggleButton', | 192 tooltip: '', |
198 TOOLBAR: 'toolbar', | 193 webArea: '', |
199 TREE_GRID: 'treeGrid', | 194 webView: '', |
200 TREE_ITEM: 'treeItem', | 195 window: '', |
201 TREE: 'tree', | 196 }; |
202 UNKNOWN: 'unknown', | 197 |
203 TOOLTIP: 'tooltip', | 198 /** |
204 VIDEO: 'video', | 199 * @enum {string} |
205 WEB_AREA: 'webArea', | |
206 WEB_VIEW: 'webView', | |
207 WINDOW: 'window', | |
208 }; | |
209 | |
210 /** | |
211 * @enum {string} | |
212 * @see https://developer.chrome.com/extensions/automation#type-StateType | |
213 */ | 200 */ |
214 chrome.automation.StateType = { | 201 chrome.automation.StateType = { |
215 BUSY: 'busy', | 202 busy: '', |
216 CHECKED: 'checked', | 203 checked: '', |
217 COLLAPSED: 'collapsed', | 204 collapsed: '', |
218 DEFAULT: 'default', | 205 default: '', |
219 DISABLED: 'disabled', | 206 disabled: '', |
220 EDITABLE: 'editable', | 207 editable: '', |
221 EXPANDED: 'expanded', | 208 expanded: '', |
222 FOCUSABLE: 'focusable', | 209 focusable: '', |
223 FOCUSED: 'focused', | 210 focused: '', |
224 HASPOPUP: 'haspopup', | 211 haspopup: '', |
225 HORIZONTAL: 'horizontal', | 212 horizontal: '', |
226 HOVERED: 'hovered', | 213 hovered: '', |
227 INVISIBLE: 'invisible', | 214 indeterminate: '', |
228 LINKED: 'linked', | 215 invisible: '', |
229 MULTILINE: 'multiline', | 216 linked: '', |
230 MULTISELECTABLE: 'multiselectable', | 217 multiline: '', |
231 OFFSCREEN: 'offscreen', | 218 multiselectable: '', |
232 PRESSED: 'pressed', | 219 offscreen: '', |
233 PROTECTED: 'protected', | 220 pressed: '', |
234 READ_ONLY: 'readOnly', | 221 protected: '', |
235 REQUIRED: 'required', | 222 readOnly: '', |
236 RICHLY_EDITABLE: 'richlyEditable', | 223 required: '', |
237 SELECTABLE: 'selectable', | 224 richlyEditable: '', |
238 SELECTED: 'selected', | 225 selectable: '', |
239 VERTICAL: 'vertical', | 226 selected: '', |
240 VISITED: 'visited', | 227 vertical: '', |
241 }; | 228 visited: '', |
242 | 229 }; |
243 /** | 230 |
244 * @enum {string} | 231 /** |
245 * @see https://developer.chrome.com/extensions/automation#type-TreeChangeType | 232 * @enum {number} |
| 233 */ |
| 234 chrome.automation.NameFromType = { |
| 235 0: '', |
| 236 1: 'uninitialized', |
| 237 2: 'attribute', |
| 238 3: 'contents', |
| 239 4: 'placeholder', |
| 240 5: 'relatedElement', |
| 241 6: 'value' |
| 242 }; |
| 243 |
| 244 /** |
| 245 * @enum {number} |
| 246 */ |
| 247 chrome.automation.DescriptionFromType = { |
| 248 0: '', |
| 249 1: 'uninitialized', |
| 250 2: 'attribute', |
| 251 3: 'contents', |
| 252 4: 'placeholder', |
| 253 5: 'relatedElement' |
| 254 }; |
| 255 |
| 256 /** |
| 257 * @enum {string} |
246 */ | 258 */ |
247 chrome.automation.TreeChangeType = { | 259 chrome.automation.TreeChangeType = { |
248 NODE_CREATED: 'nodeCreated', | 260 nodeCreated: 'nodeCreated', |
249 SUBTREE_CREATED: 'subtreeCreated', | 261 subtreeCreated: 'subtreeCreated', |
250 NODE_CHANGED: 'nodeChanged', | 262 nodeChanged: 'nodeChanged', |
251 TEXT_CHANGED: 'textChanged', | 263 nodeRemoved: 'nodeRemoved', |
252 NODE_REMOVED: 'nodeRemoved', | 264 }; |
253 }; | 265 |
254 | 266 /** |
255 /** | |
256 * @enum {string} | |
257 * @see https://developer.chrome.com/extensions/automation#type-NameFromType | |
258 */ | |
259 chrome.automation.NameFromType = { | |
260 UNINITIALIZED: 'uninitialized', | |
261 ATTRIBUTE: 'attribute', | |
262 CONTENTS: 'contents', | |
263 PLACEHOLDER: 'placeholder', | |
264 RELATED_ELEMENT: 'related_element', | |
265 VALUE: 'value', | |
266 }; | |
267 | |
268 /** | |
269 * @typedef {{ | 267 * @typedef {{ |
270 * left: number, | 268 * left: number, |
271 * top: number, | 269 * top: number, |
272 * width: number, | 270 * width: number, |
273 * height: number | 271 * height: number |
274 * }} | 272 * }} |
275 * @see https://developer.chrome.com/extensions/automation#type-Rect | |
276 */ | 273 */ |
277 chrome.automation.Rect; | 274 chrome.automation.Rect; |
278 | 275 |
279 /** | 276 /** |
280 * @typedef {{ | 277 * @typedef {{ |
281 * role: (!chrome.automation.RoleType|undefined), | 278 * role: (!chrome.automation.RoleType|undefined), |
282 * state: (Object|undefined), | 279 * state: (Object|undefined), |
283 * attributes: (Object|undefined) | 280 * attributes: (Object|undefined) |
284 * }} | 281 * }} |
285 * @see https://developer.chrome.com/extensions/automation#type-FindParams | |
286 */ | 282 */ |
287 chrome.automation.FindParams; | 283 chrome.automation.FindParams; |
288 | 284 |
289 /** | 285 /** |
| 286 * @constructor |
| 287 * @param {chrome.automation.EventType} type |
| 288 * @param {chrome.automation.AutomationNode} node |
| 289 * @param {string} eventFrom |
| 290 */ |
| 291 chrome.automation.AutomationEvent = function(type, node, eventFrom) {}; |
| 292 |
| 293 /** |
| 294 * @type {!chrome.automation.AutomationNode} |
| 295 */ |
| 296 chrome.automation.AutomationEvent.prototype.target; |
| 297 |
| 298 /** |
| 299 * @type {!chrome.automation.EventType} |
| 300 */ |
| 301 chrome.automation.AutomationEvent.prototype.type; |
| 302 |
| 303 /** |
| 304 * @type {string} |
| 305 */ |
| 306 chrome.automation.AutomationEvent.prototype.eventFrom; |
| 307 |
| 308 /** |
| 309 * @type {number} |
| 310 */ |
| 311 chrome.automation.AutomationEvent.prototype.mouseX; |
| 312 |
| 313 /** |
| 314 * @type {number} |
| 315 */ |
| 316 chrome.automation.AutomationEvent.prototype.mouseY; |
| 317 |
| 318 chrome.automation.AutomationEvent.prototype.stopPropagation = function() {}; |
| 319 |
| 320 /** |
290 * @typedef {{ | 321 * @typedef {{ |
291 * anchorObject: Object, | 322 * target: chrome.automation.AutomationNode, |
292 * anchorOffset: number, | |
293 * focusObject: Object, | |
294 * focusOffset: number | |
295 * }} | |
296 * @see https://developer.chrome.com/extensions/automation#type-SetDocumentSelec
tionParams | |
297 */ | |
298 chrome.automation.SetDocumentSelectionParams; | |
299 | |
300 /** | |
301 * @constructor | |
302 * @private | |
303 * @see https://developer.chrome.com/extensions/automation#type-AutomationEvent | |
304 */ | |
305 chrome.automation.AutomationEvent = function() {}; | |
306 | |
307 /** | |
308 * The $(ref:automation.AutomationNode) to which the event was targeted. | |
309 * @type {!chrome.automation.AutomationNode} | |
310 * @see https://developer.chrome.com/extensions/automation#type-target | |
311 */ | |
312 chrome.automation.AutomationEvent.prototype.target; | |
313 | |
314 /** | |
315 * The type of the event. | |
316 * @type {!chrome.automation.EventType} | |
317 * @see https://developer.chrome.com/extensions/automation#type-type | |
318 */ | |
319 chrome.automation.AutomationEvent.prototype.type; | |
320 | |
321 /** | |
322 * The source of this event. | |
323 * @type {string} | |
324 * @see https://developer.chrome.com/extensions/automation#type-eventFrom | |
325 */ | |
326 chrome.automation.AutomationEvent.prototype.eventFrom; | |
327 | |
328 /** | |
329 * @type {number} | |
330 * @see https://developer.chrome.com/extensions/automation#type-mouseX | |
331 */ | |
332 chrome.automation.AutomationEvent.prototype.mouseX; | |
333 | |
334 /** | |
335 * @type {number} | |
336 * @see https://developer.chrome.com/extensions/automation#type-mouseY | |
337 */ | |
338 chrome.automation.AutomationEvent.prototype.mouseY; | |
339 | |
340 /** | |
341 * Stops this event from further processing except for any remaining listeners | |
342 * on $(ref:AutomationEvent.target). | |
343 * @see https://developer.chrome.com/extensions/automation#method-stopPropagatio
n | |
344 */ | |
345 chrome.automation.AutomationEvent.prototype.stopPropagation = function() {}; | |
346 | |
347 | |
348 /** | |
349 * @typedef {{ | |
350 * target: !chrome.automation.AutomationNode, | |
351 * type: !chrome.automation.TreeChangeType | 323 * type: !chrome.automation.TreeChangeType |
352 * }} | 324 * }} |
353 * @see https://developer.chrome.com/extensions/automation#type-TreeChange | |
354 */ | 325 */ |
355 chrome.automation.TreeChange; | 326 chrome.automation.TreeChange; |
356 | 327 |
357 /** | 328 /** |
358 * @enum {string} | |
359 * @see https://developer.chrome.com/extensions/automation#type-TreeChangeObserv
erFilter | |
360 */ | |
361 chrome.automation.TreeChangeObserverFilter = { | |
362 NO_TREE_CHANGES: 'noTreeChanges', | |
363 LIVE_REGION_TREE_CHANGES: 'liveRegionTreeChanges', | |
364 TEXT_MARKER_CHANGES: 'textMarkerChanges', | |
365 ALL_TREE_CHANGES: 'allTreeChanges', | |
366 }; | |
367 | |
368 /** | |
369 * @constructor | 329 * @constructor |
370 * @private | |
371 * @see https://developer.chrome.com/extensions/automation#type-AutomationNode | |
372 */ | 330 */ |
373 chrome.automation.AutomationNode = function() {}; | 331 chrome.automation.AutomationNode = function() {}; |
374 | 332 |
375 /** | 333 |
376 * The root node of the tree containing this AutomationNode. | 334 /** |
377 * @type {(!chrome.automation.AutomationNode|undefined)} | 335 * @param {number} tabId |
378 * @see https://developer.chrome.com/extensions/automation#type-root | 336 * @param {function(chrome.automation.AutomationNode):void} callback |
| 337 */ |
| 338 chrome.automation.getTree = function(tabId, callback) {}; |
| 339 |
| 340 /** @param {function(!chrome.automation.AutomationNode):void} callback */ |
| 341 chrome.automation.getDesktop = function(callback) {}; |
| 342 |
| 343 /** @param {function(!chrome.automation.AutomationNode):void} callback */ |
| 344 chrome.automation.getFocus = function(callback) {}; |
| 345 |
| 346 /** |
| 347 * @param {string} filter |
| 348 * @param {function(chrome.automation.TreeChange) : void} |
| 349 * observer |
| 350 */ |
| 351 chrome.automation.addTreeChangeObserver = function(filter, observer) {}; |
| 352 |
| 353 /** |
| 354 * @param {function(chrome.automation.TreeChange) : void} observer |
| 355 */ |
| 356 chrome.automation.removeTreeChangeObserver = function(observer) {}; |
| 357 |
| 358 // |
| 359 // End auto generated externs; do not edit. |
| 360 // |
| 361 |
| 362 |
| 363 |
| 364 /** |
| 365 * @type {chrome.automation.RoleType} |
| 366 */ |
| 367 chrome.automation.AutomationNode.prototype.role; |
| 368 |
| 369 |
| 370 /** |
| 371 * @type {!Object<chrome.automation.StateType, boolean>} |
| 372 */ |
| 373 chrome.automation.AutomationNode.prototype.state; |
| 374 |
| 375 |
| 376 /** |
| 377 * @type {chrome.automation.NameFromType} |
| 378 */ |
| 379 chrome.automation.AutomationNode.prototype.nameFrom; |
| 380 |
| 381 |
| 382 /** |
| 383 * @type {chrome.automation.DescriptionFromType} |
| 384 */ |
| 385 chrome.automation.AutomationNode.prototype.descriptionFrom; |
| 386 |
| 387 |
| 388 /** |
| 389 * @type {number} |
| 390 */ |
| 391 chrome.automation.AutomationNode.prototype.indexInParent; |
| 392 |
| 393 |
| 394 /** |
| 395 * @type {string} |
| 396 */ |
| 397 chrome.automation.AutomationNode.prototype.name; |
| 398 |
| 399 /** |
| 400 * @type {string} |
| 401 */ |
| 402 chrome.automation.AutomationNode.prototype.description; |
| 403 |
| 404 |
| 405 /** |
| 406 * @type {string} |
| 407 */ |
| 408 chrome.automation.AutomationNode.prototype.url; |
| 409 |
| 410 |
| 411 /** |
| 412 * @type {string} |
| 413 */ |
| 414 chrome.automation.AutomationNode.prototype.docUrl; |
| 415 |
| 416 |
| 417 /** |
| 418 * @type {string} |
| 419 */ |
| 420 chrome.automation.AutomationNode.prototype.value; |
| 421 |
| 422 |
| 423 /** |
| 424 * @type {number} |
| 425 */ |
| 426 chrome.automation.AutomationNode.prototype.textSelStart; |
| 427 |
| 428 |
| 429 /** |
| 430 * @type {number} |
| 431 */ |
| 432 chrome.automation.AutomationNode.prototype.textSelEnd; |
| 433 |
| 434 |
| 435 /** |
| 436 * @type {Array<number>} |
| 437 */ |
| 438 chrome.automation.AutomationNode.prototype.wordStarts; |
| 439 |
| 440 |
| 441 /** |
| 442 * @type {Array<number>} |
| 443 */ |
| 444 chrome.automation.AutomationNode.prototype.wordEnds; |
| 445 |
| 446 |
| 447 /** |
| 448 * @type {chrome.automation.AutomationRootNode} |
379 */ | 449 */ |
380 chrome.automation.AutomationNode.prototype.root; | 450 chrome.automation.AutomationNode.prototype.root; |
381 | 451 |
382 /** | 452 |
383 * Whether this AutomationNode is a root node. | 453 /** |
384 * @type {boolean} | 454 * @type {chrome.automation.AutomationNode} |
385 * @see https://developer.chrome.com/extensions/automation#type-isRootNode | 455 */ |
386 */ | 456 chrome.automation.AutomationNode.prototype.firstChild; |
387 chrome.automation.AutomationNode.prototype.isRootNode; | 457 |
388 | 458 |
389 /** | 459 /** |
390 * The role of this node. | 460 * @type {chrome.automation.AutomationNode} |
391 * @type {(!chrome.automation.RoleType|undefined)} | 461 */ |
392 * @see https://developer.chrome.com/extensions/automation#type-role | 462 chrome.automation.AutomationNode.prototype.lastChild; |
393 */ | 463 |
394 chrome.automation.AutomationNode.prototype.role; | 464 |
395 | 465 /** |
396 /** | 466 * @type {chrome.automation.AutomationNode} |
397 * The $(ref:automation.StateType)s describing this node. | 467 */ |
398 * @type {Object<chrome.automation.StateType, boolean>} | 468 chrome.automation.AutomationNode.prototype.nextSibling; |
399 * @see https://developer.chrome.com/extensions/automation#type-state | 469 |
400 */ | 470 |
401 chrome.automation.AutomationNode.prototype.state; | 471 /** |
402 | 472 * @type {chrome.automation.AutomationNode} |
403 /** | 473 */ |
404 * The rendered location (as a bounding box) of this node in global screen coord
inates. | 474 chrome.automation.AutomationNode.prototype.previousSibling; |
405 * @type {(!chrome.automation.Rect|undefined)} | 475 |
406 * @see https://developer.chrome.com/extensions/automation#type-location | 476 |
| 477 /** |
| 478 * @type {chrome.automation.AutomationNode} |
| 479 */ |
| 480 chrome.automation.AutomationNode.prototype.parent; |
| 481 |
| 482 |
| 483 /** |
| 484 * @type {!Array<chrome.automation.AutomationNode>} |
| 485 */ |
| 486 chrome.automation.AutomationNode.prototype.children; |
| 487 |
| 488 |
| 489 /** |
| 490 * @type {{top: number, left: number, height: number, width: number}|undefined} |
407 */ | 491 */ |
408 chrome.automation.AutomationNode.prototype.location; | 492 chrome.automation.AutomationNode.prototype.location; |
409 | 493 |
410 /** | 494 |
411 * Computes the bounding box of a subrange of this node in global screen | 495 /** |
412 * coordinates. Returns the same as |location| if range information is not | 496 * @param {number} start |
413 * available. The start and end indices are zero-based offsets into the node's | 497 * @param {number} end |
414 * "name" string attribute. | 498 * @return { |
415 * @param {number} startIndex | 499 * ({top: number, left: number, height: number, width: number})|undefined} |
416 * @param {number} endIndex | 500 */ |
417 * @return {!chrome.automation.Rect} | 501 chrome.automation.AutomationNode.prototype.boundsForRange = |
418 * @see https://developer.chrome.com/extensions/automation#method-boundsForRange | 502 function(start, end) {}; |
419 */ | 503 |
420 chrome.automation.AutomationNode.prototype.boundsForRange = function(startIndex,
endIndex) {}; | 504 |
421 | 505 chrome.automation.AutomationNode.prototype.makeVisible = function() {}; |
422 /** | 506 |
423 * The purpose of the node, other than the role, if any. | 507 |
424 * @type {(string|undefined)} | 508 /** |
425 * @see https://developer.chrome.com/extensions/automation#type-description | 509 * @param {chrome.automation.EventType} eventType |
426 */ | 510 * @param {function(!chrome.automation.AutomationEvent) : void} callback |
427 chrome.automation.AutomationNode.prototype.description; | 511 * @param {boolean} capture |
428 | 512 */ |
429 /** | 513 chrome.automation.AutomationNode.prototype.addEventListener = |
430 * The placeholder for this text field, if any. | 514 function(eventType, callback, capture) {}; |
431 * @type {(string|undefined)} | 515 |
432 * @see https://developer.chrome.com/extensions/automation#type-placeholder | 516 |
433 */ | 517 /** |
434 chrome.automation.AutomationNode.prototype.placeholder; | 518 * @param {chrome.automation.EventType} eventType |
435 | 519 * @param {function(!chrome.automation.AutomationEvent) : void} callback |
436 /** | 520 * @param {boolean} capture |
437 * The accessible name for this node, via the <a href="http://www.w3.org/TR/wai-
aria/roles#namecalculation"> Accessible Name Calculation</a> process. | 521 */ |
438 * @type {(string|undefined)} | 522 chrome.automation.AutomationNode.prototype.removeEventListener = |
439 * @see https://developer.chrome.com/extensions/automation#type-name | 523 function(eventType, callback, capture) {}; |
440 */ | 524 |
441 chrome.automation.AutomationNode.prototype.name; | 525 |
442 | 526 /** |
443 /** | 527 * @type {chrome.automation.AutomationNode} |
444 * The source of the name. | 528 */ |
445 * @type {(!chrome.automation.NameFromType|undefined)} | 529 chrome.automation.TreeChange.prototype.target; |
446 * @see https://developer.chrome.com/extensions/automation#type-nameFrom | 530 |
447 */ | 531 |
448 chrome.automation.AutomationNode.prototype.nameFrom; | 532 /** |
449 | 533 * @type {chrome.automation.TreeChangeType} |
450 /** | 534 */ |
451 * The value for this node: for example the <code>value</code> attribute of an <
code><input> element. | 535 chrome.automation.TreeChange.prototype.type; |
452 * @type {(string|undefined)} | 536 |
453 * @see https://developer.chrome.com/extensions/automation#type-value | 537 |
454 */ | 538 chrome.automation.AutomationNode.prototype.doDefault = function() {}; |
455 chrome.automation.AutomationNode.prototype.value; | 539 |
456 | 540 |
457 /** | 541 chrome.automation.AutomationNode.prototype.focus = function() {}; |
458 * The HTML tag for this element, if this node is an HTML element. | 542 |
459 * @type {(string|undefined)} | 543 |
460 * @see https://developer.chrome.com/extensions/automation#type-htmlTag | 544 chrome.automation.AutomationNode.prototype.showContextMenu = function() {}; |
461 */ | 545 |
462 chrome.automation.AutomationNode.prototype.htmlTag; | 546 |
463 | 547 chrome.automation.AutomationNode.prototype |
464 /** | 548 .setSequentialFocusNavigationStartingPoint = function() {}; |
465 * The level of a heading or tree item. | 549 |
| 550 |
| 551 /** |
| 552 * @param {number} start |
| 553 * @param {number} end |
| 554 */ |
| 555 chrome.automation.AutomationNode.prototype.setSelection = |
| 556 function(start, end) {}; |
| 557 |
| 558 /** @type {string} */ |
| 559 chrome.automation.AutomationNode.prototype.containerLiveStatus; |
| 560 |
| 561 /** @type {string} */ |
| 562 chrome.automation.AutomationNode.prototype.containerLiveRelevant; |
| 563 |
| 564 /** @type {boolean} */ |
| 565 chrome.automation.AutomationNode.prototype.containerLiveAtomic; |
| 566 |
| 567 /** @type {boolean} */ |
| 568 chrome.automation.AutomationNode.prototype.containerLiveBusy; |
| 569 |
| 570 /** @type {string} */ |
| 571 chrome.automation.AutomationNode.prototype.language; |
| 572 |
| 573 /** @type {string} */ |
| 574 chrome.automation.AutomationNode.prototype.liveStatus; |
| 575 |
| 576 /** @type {string} */ |
| 577 chrome.automation.AutomationNode.prototype.liveRelevant; |
| 578 |
| 579 /** @type {boolean} */ |
| 580 chrome.automation.AutomationNode.prototype.liveAtomic; |
| 581 |
| 582 /** @type {boolean} */ |
| 583 chrome.automation.AutomationNode.prototype.liveBusy; |
| 584 |
| 585 |
| 586 /** |
| 587 * @param {Object} findParams |
| 588 */ |
| 589 chrome.automation.AutomationNode.prototype.find = function(findParams) {}; |
| 590 |
| 591 /** |
| 592 * @param {Object} findParams |
| 593 * @return {Array<chrome.automation.AutomationNode>} |
| 594 */ |
| 595 chrome.automation.AutomationNode.prototype.findAll = function(findParams) {}; |
| 596 |
| 597 /** |
| 598 * @type {string} |
| 599 */ |
| 600 chrome.automation.AutomationNode.prototype.inputType; |
| 601 |
| 602 /** |
| 603 * @type {(chrome.automation.AutomationNode|undefined)} |
| 604 */ |
| 605 chrome.automation.AutomationNode.prototype.anchorObject; |
| 606 |
| 607 /** |
| 608 * @param {{anchorObject: !chrome.automation.AutomationNode, |
| 609 * anchorOffset: number, |
| 610 * focusObject: !chrome.automation.AutomationNode, |
| 611 * focusOffset: number}} selectionParams |
| 612 */ |
| 613 chrome.automation.setDocumentSelection = function(selectionParams) {}; |
| 614 |
| 615 /** |
466 * @type {(number|undefined)} | 616 * @type {(number|undefined)} |
467 * @see https://developer.chrome.com/extensions/automation#type-hierarchicalLeve
l | 617 */ |
468 */ | 618 chrome.automation.anchorOffset; |
| 619 |
| 620 /** |
| 621 * @type {(chrome.automation.AutomationNode|undefined)} |
| 622 */ |
| 623 chrome.automation.AutomationNode.prototype.focusObject; |
| 624 |
| 625 /** |
| 626 * @type {(Array<number>|undefined)} |
| 627 */ |
| 628 chrome.automation.AutomationNode.prototype.lineBreaks; |
| 629 |
| 630 /** |
| 631 * @type {(number|undefined)} |
| 632 */ |
| 633 chrome.automation.focusOffset; |
| 634 |
| 635 /** |
| 636 * @type {(chrome.automation.AutomationNode|undefined)} |
| 637 */ |
| 638 chrome.automation.AutomationNode.prototype.activeDescendant; |
| 639 |
| 640 /** @type {number} */ |
| 641 chrome.automation.AutomationNode.prototype.tableCellColumnIndex; |
| 642 |
| 643 /** @type {number} */ |
| 644 chrome.automation.AutomationNode.prototype.tableCellRowIndex; |
| 645 |
| 646 /** @type {number} */ |
| 647 chrome.automation.AutomationNode.prototype.tableColumnCount; |
| 648 |
| 649 /** @type {number} */ |
| 650 chrome.automation.AutomationNode.prototype.tableRowCount; |
| 651 |
| 652 /** @type {number} */ |
469 chrome.automation.AutomationNode.prototype.hierarchicalLevel; | 653 chrome.automation.AutomationNode.prototype.hierarchicalLevel; |
470 | 654 |
471 /** | 655 /** @type {Array<number>} */ |
472 * The start and end index of each word in an inline text box. | 656 chrome.automation.AutomationNode.prototype.markerTypes; |
473 * @type {(!Array<number>|undefined)} | 657 /** @type {Array<number>} */ |
474 * @see https://developer.chrome.com/extensions/automation#type-wordStarts | |
475 */ | |
476 chrome.automation.AutomationNode.prototype.wordStarts; | |
477 | |
478 /** | |
479 * @type {(!Array<number>|undefined)} | |
480 * @see https://developer.chrome.com/extensions/automation#type-wordEnds | |
481 */ | |
482 chrome.automation.AutomationNode.prototype.wordEnds; | |
483 | |
484 /** | |
485 * The nodes, if any, which this node is specified to control via <a href="http:
//www.w3.org/TR/wai-aria/states_and_properties#aria-controls"> <code>aria-contro
ls</code></a>. | |
486 * @type {(!Array<!chrome.automation.AutomationNode>|undefined)} | |
487 * @see https://developer.chrome.com/extensions/automation#type-controls | |
488 */ | |
489 chrome.automation.AutomationNode.prototype.controls; | |
490 | |
491 /** | |
492 * The nodes, if any, which form a description for this node. | |
493 * @type {(!Array<!chrome.automation.AutomationNode>|undefined)} | |
494 * @see https://developer.chrome.com/extensions/automation#type-describedBy | |
495 */ | |
496 chrome.automation.AutomationNode.prototype.describedBy; | |
497 | |
498 /** | |
499 * The nodes, if any, which may optionally be navigated to after this one. See <
a href="http://www.w3.org/TR/wai-aria/states_and_properties#aria-flowto"> <code>
aria-flowto</code></a>. | |
500 * @type {(!Array<!chrome.automation.AutomationNode>|undefined)} | |
501 * @see https://developer.chrome.com/extensions/automation#type-flowTo | |
502 */ | |
503 chrome.automation.AutomationNode.prototype.flowTo; | |
504 | |
505 /** | |
506 * The nodes, if any, which form a label for this element. Generally, the text f
rom these elements will also be exposed as the element's accessible name, via th
e $(ref:automation.AutomationNode.name) attribute. | |
507 * @type {(!Array<!chrome.automation.AutomationNode>|undefined)} | |
508 * @see https://developer.chrome.com/extensions/automation#type-labelledBy | |
509 */ | |
510 chrome.automation.AutomationNode.prototype.labelledBy; | |
511 | |
512 /** | |
513 * The node referred to by <code>aria-activedescendant</code>, where applicable | |
514 * @type {(!chrome.automation.AutomationNode|undefined)} | |
515 * @see https://developer.chrome.com/extensions/automation#type-activeDescendant | |
516 */ | |
517 chrome.automation.AutomationNode.prototype.activeDescendant; | |
518 | |
519 /** | |
520 * The URL that this link will navigate to. | |
521 * @type {(string|undefined)} | |
522 * @see https://developer.chrome.com/extensions/automation#type-url | |
523 */ | |
524 chrome.automation.AutomationNode.prototype.url; | |
525 | |
526 /** | |
527 * The URL of this document. | |
528 * @type {(string|undefined)} | |
529 * @see https://developer.chrome.com/extensions/automation#type-docUrl | |
530 */ | |
531 chrome.automation.AutomationNode.prototype.docUrl; | |
532 | |
533 /** | |
534 * The title of this document. | |
535 * @type {(string|undefined)} | |
536 * @see https://developer.chrome.com/extensions/automation#type-docTitle | |
537 */ | |
538 chrome.automation.AutomationNode.prototype.docTitle; | |
539 | |
540 /** | |
541 * Whether this document has finished loading. | |
542 * @type {(boolean|undefined)} | |
543 * @see https://developer.chrome.com/extensions/automation#type-docLoaded | |
544 */ | |
545 chrome.automation.AutomationNode.prototype.docLoaded; | |
546 | |
547 /** | |
548 * The proportion (out of 1.0) that this doc has completed loading. | |
549 * @type {(number|undefined)} | |
550 * @see https://developer.chrome.com/extensions/automation#type-docLoadingProgre
ss | |
551 */ | |
552 chrome.automation.AutomationNode.prototype.docLoadingProgress; | |
553 | |
554 /** | |
555 * Scrollable container attributes. | |
556 * @type {(number|undefined)} | |
557 * @see https://developer.chrome.com/extensions/automation#type-scrollX | |
558 */ | |
559 chrome.automation.AutomationNode.prototype.scrollX; | |
560 | |
561 /** | |
562 * @type {(number|undefined)} | |
563 * @see https://developer.chrome.com/extensions/automation#type-scrollXMin | |
564 */ | |
565 chrome.automation.AutomationNode.prototype.scrollXMin; | |
566 | |
567 /** | |
568 * @type {(number|undefined)} | |
569 * @see https://developer.chrome.com/extensions/automation#type-scrollXMax | |
570 */ | |
571 chrome.automation.AutomationNode.prototype.scrollXMax; | |
572 | |
573 /** | |
574 * @type {(number|undefined)} | |
575 * @see https://developer.chrome.com/extensions/automation#type-scrollY | |
576 */ | |
577 chrome.automation.AutomationNode.prototype.scrollY; | |
578 | |
579 /** | |
580 * @type {(number|undefined)} | |
581 * @see https://developer.chrome.com/extensions/automation#type-scrollYMin | |
582 */ | |
583 chrome.automation.AutomationNode.prototype.scrollYMin; | |
584 | |
585 /** | |
586 * @type {(number|undefined)} | |
587 * @see https://developer.chrome.com/extensions/automation#type-scrollYMax | |
588 */ | |
589 chrome.automation.AutomationNode.prototype.scrollYMax; | |
590 | |
591 /** | |
592 * The character index of the start of the selection within this editable text e
lement; -1 if no selection. | |
593 * @type {(number|undefined)} | |
594 * @see https://developer.chrome.com/extensions/automation#type-textSelStart | |
595 */ | |
596 chrome.automation.AutomationNode.prototype.textSelStart; | |
597 | |
598 /** | |
599 * The character index of the end of the selection within this editable text ele
ment; -1 if no selection. | |
600 * @type {(number|undefined)} | |
601 * @see https://developer.chrome.com/extensions/automation#type-textSelEnd | |
602 */ | |
603 chrome.automation.AutomationNode.prototype.textSelEnd; | |
604 | |
605 /** | |
606 * The input type, like email or number. | |
607 * @type {(string|undefined)} | |
608 * @see https://developer.chrome.com/extensions/automation#type-textInputType | |
609 */ | |
610 chrome.automation.AutomationNode.prototype.textInputType; | |
611 | |
612 /** | |
613 * An array of indexes of the break between lines in editable text. | |
614 * @type {!Array<number>} | |
615 * @see https://developer.chrome.com/extensions/automation#type-lineBreaks | |
616 */ | |
617 chrome.automation.AutomationNode.prototype.lineBreaks; | |
618 | |
619 /** | |
620 * An array of indexes of the start position of each text marker. | |
621 * @type {!Array<number>} | |
622 * @see https://developer.chrome.com/extensions/automation#type-markerStarts | |
623 */ | |
624 chrome.automation.AutomationNode.prototype.markerStarts; | 658 chrome.automation.AutomationNode.prototype.markerStarts; |
625 | 659 /** @type {Array<number>} */ |
626 /** | |
627 * An array of indexes of the end position of each text marker. | |
628 * @type {!Array<number>} | |
629 * @see https://developer.chrome.com/extensions/automation#type-markerEnds | |
630 */ | |
631 chrome.automation.AutomationNode.prototype.markerEnds; | 660 chrome.automation.AutomationNode.prototype.markerEnds; |
632 | 661 |
633 /** | 662 /** @type {boolean} */ |
634 * An array of numerical types indicating the type of each text marker, such as
a spelling error. | 663 chrome.automation.AutomationNode.prototype.ariaReadonly; |
635 * @type {!Array<number>} | 664 |
636 * @see https://developer.chrome.com/extensions/automation#type-markerTypes | 665 /** @type {chrome.automation.AutomationNode} */ |
637 */ | 666 chrome.automation.AutomationNode.prototype.nextOnLine; |
638 chrome.automation.AutomationNode.prototype.markerTypes; | 667 /** @type {chrome.automation.AutomationNode} */ |
639 | 668 chrome.automation.AutomationNode.prototype.previousOnLine; |
640 /** | 669 |
641 * The anchor node of the tree selection, if any. | 670 /** @type {Object<string, string>} */ |
642 * @type {(!chrome.automation.AutomationNode|undefined)} | |
643 * @see https://developer.chrome.com/extensions/automation#type-anchorObject | |
644 */ | |
645 chrome.automation.AutomationNode.prototype.anchorObject; | |
646 | |
647 /** | |
648 * The anchor offset of the tree selection, if any. | |
649 * @type {(number|undefined)} | |
650 * @see https://developer.chrome.com/extensions/automation#type-anchorOffset | |
651 */ | |
652 chrome.automation.AutomationNode.prototype.anchorOffset; | |
653 | |
654 /** | |
655 * The affinity of the tree selection anchor, if any. | |
656 * @type {(string|undefined)} | |
657 * @see https://developer.chrome.com/extensions/automation#type-anchorAffinity | |
658 */ | |
659 chrome.automation.AutomationNode.prototype.anchorAffinity; | |
660 | |
661 /** | |
662 * The focus node of the tree selection, if any. | |
663 * @type {(!chrome.automation.AutomationNode|undefined)} | |
664 * @see https://developer.chrome.com/extensions/automation#type-focusObject | |
665 */ | |
666 chrome.automation.AutomationNode.prototype.focusObject; | |
667 | |
668 /** | |
669 * The focus offset of the tree selection, if any. | |
670 * @type {(number|undefined)} | |
671 * @see https://developer.chrome.com/extensions/automation#type-focusOffset | |
672 */ | |
673 chrome.automation.AutomationNode.prototype.focusOffset; | |
674 | |
675 /** | |
676 * The affinity of the tree selection focus, if any. | |
677 * @type {(string|undefined)} | |
678 * @see https://developer.chrome.com/extensions/automation#type-focusAffinity | |
679 */ | |
680 chrome.automation.AutomationNode.prototype.focusAffinity; | |
681 | |
682 /** | |
683 * The current value for this range. | |
684 * @type {(number|undefined)} | |
685 * @see https://developer.chrome.com/extensions/automation#type-valueForRange | |
686 */ | |
687 chrome.automation.AutomationNode.prototype.valueForRange; | |
688 | |
689 /** | |
690 * The minimum possible value for this range. | |
691 * @type {(number|undefined)} | |
692 * @see https://developer.chrome.com/extensions/automation#type-minValueForRange | |
693 */ | |
694 chrome.automation.AutomationNode.prototype.minValueForRange; | |
695 | |
696 /** | |
697 * The maximum possible value for this range. | |
698 * @type {(number|undefined)} | |
699 * @see https://developer.chrome.com/extensions/automation#type-maxValueForRange | |
700 */ | |
701 chrome.automation.AutomationNode.prototype.maxValueForRange; | |
702 | |
703 /** | |
704 * The 1-based index of an item in a set. | |
705 * @type {(number|undefined)} | |
706 * @see https://developer.chrome.com/extensions/automation#type-posInSet | |
707 */ | |
708 chrome.automation.AutomationNode.prototype.posInSet; | |
709 | |
710 /** | |
711 * The number of items in a set; | |
712 * @type {(number|undefined)} | |
713 * @see https://developer.chrome.com/extensions/automation#type-setSize | |
714 */ | |
715 chrome.automation.AutomationNode.prototype.setSize; | |
716 | |
717 /** | |
718 * The number of rows in this table. | |
719 * @type {(number|undefined)} | |
720 * @see https://developer.chrome.com/extensions/automation#type-tableRowCount | |
721 */ | |
722 chrome.automation.AutomationNode.prototype.tableRowCount; | |
723 | |
724 /** | |
725 * The number of columns in this table. | |
726 * @type {(number|undefined)} | |
727 * @see https://developer.chrome.com/extensions/automation#type-tableColumnCount | |
728 */ | |
729 chrome.automation.AutomationNode.prototype.tableColumnCount; | |
730 | |
731 /** | |
732 * The zero-based index of the column that this cell is in. | |
733 * @type {(number|undefined)} | |
734 * @see https://developer.chrome.com/extensions/automation#type-tableCellColumnI
ndex | |
735 */ | |
736 chrome.automation.AutomationNode.prototype.tableCellColumnIndex; | |
737 | |
738 /** | |
739 * The number of columns that this cell spans (default is 1). | |
740 * @type {(number|undefined)} | |
741 * @see https://developer.chrome.com/extensions/automation#type-tableCellColumnS
pan | |
742 */ | |
743 chrome.automation.AutomationNode.prototype.tableCellColumnSpan; | |
744 | |
745 /** | |
746 * The zero-based index of the row that this cell is in. | |
747 * @type {(number|undefined)} | |
748 * @see https://developer.chrome.com/extensions/automation#type-tableCellRowInde
x | |
749 */ | |
750 chrome.automation.AutomationNode.prototype.tableCellRowIndex; | |
751 | |
752 /** | |
753 * The number of rows that this cell spans (default is 1). | |
754 * @type {(number|undefined)} | |
755 * @see https://developer.chrome.com/extensions/automation#type-tableCellRowSpan | |
756 */ | |
757 chrome.automation.AutomationNode.prototype.tableCellRowSpan; | |
758 | |
759 /** | |
760 * The corresponding column header for this cell. | |
761 * @type {(!chrome.automation.AutomationNode|undefined)} | |
762 * @see https://developer.chrome.com/extensions/automation#type-tableColumnHeade
r | |
763 */ | |
764 chrome.automation.AutomationNode.prototype.tableColumnHeader; | |
765 | |
766 /** | |
767 * The corresponding row header for this cell. | |
768 * @type {(!chrome.automation.AutomationNode|undefined)} | |
769 * @see https://developer.chrome.com/extensions/automation#type-tableRowHeader | |
770 */ | |
771 chrome.automation.AutomationNode.prototype.tableRowHeader; | |
772 | |
773 /** | |
774 * The type of region if this is the root of a live region. Possible values are
'polite' and 'assertive'. | |
775 * @type {(string|undefined)} | |
776 * @see https://developer.chrome.com/extensions/automation#type-liveStatus | |
777 */ | |
778 chrome.automation.AutomationNode.prototype.liveStatus; | |
779 | |
780 /** | |
781 * The value of aria-relevant for a live region. | |
782 * @type {(string|undefined)} | |
783 * @see https://developer.chrome.com/extensions/automation#type-liveRelevant | |
784 */ | |
785 chrome.automation.AutomationNode.prototype.liveRelevant; | |
786 | |
787 /** | |
788 * The value of aria-atomic for a live region. | |
789 * @type {(boolean|undefined)} | |
790 * @see https://developer.chrome.com/extensions/automation#type-liveAtomic | |
791 */ | |
792 chrome.automation.AutomationNode.prototype.liveAtomic; | |
793 | |
794 /** | |
795 * The value of aria-busy for a live region. | |
796 * @type {(boolean|undefined)} | |
797 * @see https://developer.chrome.com/extensions/automation#type-liveBusy | |
798 */ | |
799 chrome.automation.AutomationNode.prototype.liveBusy; | |
800 | |
801 /** | |
802 * The type of live region if this node is inside a live region. | |
803 * @type {(string|undefined)} | |
804 * @see https://developer.chrome.com/extensions/automation#type-containerLiveSta
tus | |
805 */ | |
806 chrome.automation.AutomationNode.prototype.containerLiveStatus; | |
807 | |
808 /** | |
809 * The value of aria-relevant if this node is inside a live region. | |
810 * @type {(string|undefined)} | |
811 * @see https://developer.chrome.com/extensions/automation#type-containerLiveRel
evant | |
812 */ | |
813 chrome.automation.AutomationNode.prototype.containerLiveRelevant; | |
814 | |
815 /** | |
816 * The value of aria-atomic if this node is inside a live region. | |
817 * @type {(boolean|undefined)} | |
818 * @see https://developer.chrome.com/extensions/automation#type-containerLiveAto
mic | |
819 */ | |
820 chrome.automation.AutomationNode.prototype.containerLiveAtomic; | |
821 | |
822 /** | |
823 * The value of aria-busy if this node is inside a live region. | |
824 * @type {(boolean|undefined)} | |
825 * @see https://developer.chrome.com/extensions/automation#type-containerLiveBus
y | |
826 */ | |
827 chrome.automation.AutomationNode.prototype.containerLiveBusy; | |
828 | |
829 /** | |
830 * A map containing all HTML attributes and their values | |
831 * @type {Object<string>} | |
832 * @see https://developer.chrome.com/extensions/automation#type-htmlAttributes | |
833 */ | |
834 chrome.automation.AutomationNode.prototype.htmlAttributes; | 671 chrome.automation.AutomationNode.prototype.htmlAttributes; |
835 | 672 |
836 /** | 673 /** |
837 * The input type of a text field, such as "text" or "email". | 674 * @extends {chrome.automation.AutomationNode} |
838 * @type {(string|undefined)} | 675 * @constructor |
839 * @see https://developer.chrome.com/extensions/automation#type-inputType | 676 */ |
840 */ | 677 chrome.automation.AutomationRootNode = function() {}; |
841 chrome.automation.AutomationNode.prototype.inputType; | 678 |
842 | 679 /** |
843 /** | 680 * @type {chrome.automation.AutomationNode} |
844 * The key that activates this widget. | 681 */ |
845 * @type {(string|undefined)} | 682 chrome.automation.AutomationRootNode.prototype.anchorObject; |
846 * @see https://developer.chrome.com/extensions/automation#type-accessKey | 683 |
847 */ | 684 /** |
848 chrome.automation.AutomationNode.prototype.accessKey; | 685 * @type {number} |
849 | 686 */ |
850 /** | 687 chrome.automation.AutomationRootNode.prototype.anchorOffset; |
851 * The value of the aria-invalid attribute, indicating the error type. | 688 |
852 * @type {(string|undefined)} | 689 /** |
853 * @see https://developer.chrome.com/extensions/automation#type-ariaInvalidValue | 690 * @type {chrome.automation.AutomationNode} |
854 */ | 691 */ |
855 chrome.automation.AutomationNode.prototype.ariaInvalidValue; | 692 chrome.automation.AutomationRootNode.prototype.focusObject; |
856 | 693 |
857 /** | 694 /** |
858 * The value of the aria-readonly attribute, if applicable. | 695 * @type {number} |
859 * @type {(boolean|undefined)} | 696 */ |
860 * @see https://developer.chrome.com/extensions/automation#type-ariaReadonly | 697 chrome.automation.AutomationRootNode.prototype.focusOffset; |
861 */ | |
862 chrome.automation.AutomationNode.prototype.ariaReadonly; | |
863 | |
864 /** | |
865 * The CSS display attribute for this node, if applicable. | |
866 * @type {(string|undefined)} | |
867 * @see https://developer.chrome.com/extensions/automation#type-display | |
868 */ | |
869 chrome.automation.AutomationNode.prototype.display; | |
870 | |
871 /** | |
872 * A data url with the contents of this object's image or thumbnail. | |
873 * @type {(string|undefined)} | |
874 * @see https://developer.chrome.com/extensions/automation#type-imageDataUrl | |
875 */ | |
876 chrome.automation.AutomationNode.prototype.imageDataUrl; | |
877 | |
878 /** | |
879 * The language code for this subtree. | |
880 * @type {(string|undefined)} | |
881 * @see https://developer.chrome.com/extensions/automation#type-language | |
882 */ | |
883 chrome.automation.AutomationNode.prototype.language; | |
884 | |
885 /** | |
886 * If a checkbox or toggle button is in the mixed state. | |
887 * @type {(boolean|undefined)} | |
888 * @see https://developer.chrome.com/extensions/automation#type-buttonMixed | |
889 */ | |
890 chrome.automation.AutomationNode.prototype.buttonMixed; | |
891 | |
892 /** | |
893 * The RGBA foreground color of this subtree, as an integer. | |
894 * @type {(number|undefined)} | |
895 * @see https://developer.chrome.com/extensions/automation#type-color | |
896 */ | |
897 chrome.automation.AutomationNode.prototype.color; | |
898 | |
899 /** | |
900 * The RGBA background color of this subtree, as an integer. | |
901 * @type {(number|undefined)} | |
902 * @see https://developer.chrome.com/extensions/automation#type-backgroundColor | |
903 */ | |
904 chrome.automation.AutomationNode.prototype.backgroundColor; | |
905 | |
906 /** | |
907 * The RGBA color of an input element whose value is a color. | |
908 * @type {(number|undefined)} | |
909 * @see https://developer.chrome.com/extensions/automation#type-colorValue | |
910 */ | |
911 chrome.automation.AutomationNode.prototype.colorValue; | |
912 | |
913 /** | |
914 * Walking the tree. | |
915 * @type {!Array<!chrome.automation.AutomationNode>} | |
916 * @see https://developer.chrome.com/extensions/automation#type-children | |
917 */ | |
918 chrome.automation.AutomationNode.prototype.children; | |
919 | |
920 /** | |
921 * @type {(!chrome.automation.AutomationNode|undefined)} | |
922 * @see https://developer.chrome.com/extensions/automation#type-parent | |
923 */ | |
924 chrome.automation.AutomationNode.prototype.parent; | |
925 | |
926 /** | |
927 * @type {(!chrome.automation.AutomationNode|undefined)} | |
928 * @see https://developer.chrome.com/extensions/automation#type-firstChild | |
929 */ | |
930 chrome.automation.AutomationNode.prototype.firstChild; | |
931 | |
932 /** | |
933 * @type {(!chrome.automation.AutomationNode|undefined)} | |
934 * @see https://developer.chrome.com/extensions/automation#type-lastChild | |
935 */ | |
936 chrome.automation.AutomationNode.prototype.lastChild; | |
937 | |
938 /** | |
939 * @type {(!chrome.automation.AutomationNode|undefined)} | |
940 * @see https://developer.chrome.com/extensions/automation#type-previousSibling | |
941 */ | |
942 chrome.automation.AutomationNode.prototype.previousSibling; | |
943 | |
944 /** | |
945 * @type {(!chrome.automation.AutomationNode|undefined)} | |
946 * @see https://developer.chrome.com/extensions/automation#type-nextSibling | |
947 */ | |
948 chrome.automation.AutomationNode.prototype.nextSibling; | |
949 | |
950 /** | |
951 * @type {(!chrome.automation.AutomationNode|undefined)} | |
952 * @see https://developer.chrome.com/extensions/automation#type-nextOnLine | |
953 */ | |
954 chrome.automation.AutomationNode.prototype.nextOnLine; | |
955 | |
956 /** | |
957 * @type {(!chrome.automation.AutomationNode|undefined)} | |
958 * @see https://developer.chrome.com/extensions/automation#type-previousOnLine | |
959 */ | |
960 chrome.automation.AutomationNode.prototype.previousOnLine; | |
961 | |
962 /** | |
963 * The index of this node in its parent node's list of children. If this is the
root node, this will be undefined. | |
964 * @type {(number|undefined)} | |
965 * @see https://developer.chrome.com/extensions/automation#type-indexInParent | |
966 */ | |
967 chrome.automation.AutomationNode.prototype.indexInParent; | |
968 | |
969 /** | |
970 * Does the default action based on this node's role. This is generally the same | |
971 * action that would result from clicking the node such as expanding a treeitem, | |
972 * toggling a checkbox, selecting a radiobutton, or activating a button. | |
973 * @see https://developer.chrome.com/extensions/automation#method-doDefault | |
974 */ | |
975 chrome.automation.AutomationNode.prototype.doDefault = function() {}; | |
976 | |
977 /** | |
978 * Places focus on this node. | |
979 * @see https://developer.chrome.com/extensions/automation#method-focus | |
980 */ | |
981 chrome.automation.AutomationNode.prototype.focus = function() {}; | |
982 | |
983 /** | |
984 * Request a data url for the contents of an image, optionally resized. Pass | |
985 * zero for maxWidth and/or maxHeight for the original size. | |
986 * @param {number} maxWidth | |
987 * @param {number} maxHeight | |
988 * @see https://developer.chrome.com/extensions/automation#method-getImageData | |
989 */ | |
990 chrome.automation.AutomationNode.prototype.getImageData = function(maxWidth, max
Height) {}; | |
991 | |
992 /** | |
993 * Scrolls this node to make it visible. | |
994 * @see https://developer.chrome.com/extensions/automation#method-makeVisible | |
995 */ | |
996 chrome.automation.AutomationNode.prototype.makeVisible = function() {}; | |
997 | |
998 /** | |
999 * Sets selection within a text field. | |
1000 * @param {number} startIndex | |
1001 * @param {number} endIndex | |
1002 * @see https://developer.chrome.com/extensions/automation#method-setSelection | |
1003 */ | |
1004 chrome.automation.AutomationNode.prototype.setSelection = function(startIndex, e
ndIndex) {}; | |
1005 | |
1006 /** | |
1007 * Clears focus and sets this node as the starting point for the next time the | |
1008 * user presses Tab or Shift+Tab. | |
1009 * @see https://developer.chrome.com/extensions/automation#method-setSequentialF
ocusNavigationStartingPoint | |
1010 */ | |
1011 chrome.automation.AutomationNode.prototype.setSequentialFocusNavigationStartingP
oint = function() {}; | |
1012 | |
1013 /** | |
1014 * Show the context menu for this element, as if the user right-clicked. | |
1015 * @see https://developer.chrome.com/extensions/automation#method-showContextMen
u | |
1016 */ | |
1017 chrome.automation.AutomationNode.prototype.showContextMenu = function() {}; | |
1018 | |
1019 /** | |
1020 * Resume playing any media within this tree. | |
1021 * @see https://developer.chrome.com/extensions/automation#method-resumeMedia | |
1022 */ | |
1023 chrome.automation.AutomationNode.prototype.resumeMedia = function() {}; | |
1024 | |
1025 /** | |
1026 * Start ducking any media within this tree. | |
1027 * @see https://developer.chrome.com/extensions/automation#method-startDuckingMe
dia | |
1028 */ | |
1029 chrome.automation.AutomationNode.prototype.startDuckingMedia = function() {}; | |
1030 | |
1031 /** | |
1032 * Stop ducking any media within this tree. | |
1033 * @see https://developer.chrome.com/extensions/automation#method-stopDuckingMed
ia | |
1034 */ | |
1035 chrome.automation.AutomationNode.prototype.stopDuckingMedia = function() {}; | |
1036 | |
1037 /** | |
1038 * Suspend any media playing within this tree. | |
1039 * @see https://developer.chrome.com/extensions/automation#method-suspendMedia | |
1040 */ | |
1041 chrome.automation.AutomationNode.prototype.suspendMedia = function() {}; | |
1042 | |
1043 /** | |
1044 * Adds a listener for the given event type and event phase. | |
1045 * @param {!chrome.automation.EventType} eventType | |
1046 * @param {function(!chrome.automation.AutomationEvent):void} listener A | |
1047 * listener for events on an <code>AutomationNode</code>. | |
1048 * @param {boolean} capture | |
1049 * @see https://developer.chrome.com/extensions/automation#method-addEventListen
er | |
1050 */ | |
1051 chrome.automation.AutomationNode.prototype.addEventListener = function(eventType
, listener, capture) {}; | |
1052 | |
1053 /** | |
1054 * Removes a listener for the given event type and event phase. | |
1055 * @param {!chrome.automation.EventType} eventType | |
1056 * @param {function(!chrome.automation.AutomationEvent):void} listener A | |
1057 * listener for events on an <code>AutomationNode</code>. | |
1058 * @param {boolean} capture | |
1059 * @see https://developer.chrome.com/extensions/automation#method-removeEventLis
tener | |
1060 */ | |
1061 chrome.automation.AutomationNode.prototype.removeEventListener = function(eventT
ype, listener, capture) {}; | |
1062 | |
1063 /** | |
1064 * <p>Gets the first node in this node's subtree which matches the given CSS | |
1065 * selector and is within the same DOM context.</p><p>If this node doesn't | |
1066 * correspond directly with an HTML node in the DOM, querySelector will be run | |
1067 * on this node's nearest HTML node ancestor. Note that this may result in the | |
1068 * query returning a node which is not a descendant of this node.</p><p>If the | |
1069 * selector matches a node which doesn't directly correspond to an automation | |
1070 * node (for example an element within an ARIA widget, where the ARIA widget | |
1071 * forms one node of the automation tree, or an element which is hidden from | |
1072 * accessibility via hiding it using CSS or using aria-hidden), this will return | |
1073 * the nearest ancestor which does correspond to an automation node.</p> | |
1074 * @param {string} selector | |
1075 * @param {function(!chrome.automation.AutomationNode):void} callback Called | |
1076 * when the result for a <code>query</code> is available. | |
1077 * @see https://developer.chrome.com/extensions/automation#method-domQuerySelect
or | |
1078 */ | |
1079 chrome.automation.AutomationNode.prototype.domQuerySelector = function(selector,
callback) {}; | |
1080 | |
1081 /** | |
1082 * Finds the first AutomationNode in this node's subtree which matches the given | |
1083 * search parameters. | |
1084 * @param {!chrome.automation.FindParams} params | |
1085 * @return {!chrome.automation.AutomationNode} | |
1086 * @see https://developer.chrome.com/extensions/automation#method-find | |
1087 */ | |
1088 chrome.automation.AutomationNode.prototype.find = function(params) {}; | |
1089 | |
1090 /** | |
1091 * Finds all the AutomationNodes in this node's subtree which matches the given | |
1092 * search parameters. | |
1093 * @param {!chrome.automation.FindParams} params | |
1094 * @return {!Array<!chrome.automation.AutomationNode>} | |
1095 * @see https://developer.chrome.com/extensions/automation#method-findAll | |
1096 */ | |
1097 chrome.automation.AutomationNode.prototype.findAll = function(params) {}; | |
1098 | |
1099 /** | |
1100 * Returns whether this node matches the given $(ref:automation.FindParams). | |
1101 * @param {!chrome.automation.FindParams} params | |
1102 * @return {boolean} | |
1103 * @see https://developer.chrome.com/extensions/automation#method-matches | |
1104 */ | |
1105 chrome.automation.AutomationNode.prototype.matches = function(params) {}; | |
1106 | |
1107 | |
1108 /** | |
1109 * Get the automation tree for the tab with the given tabId, or the current tab | |
1110 * if no tabID is given, enabling automation if necessary. Returns a tree with a | |
1111 * placeholder root node; listen for the "loadComplete" event to get a | |
1112 * notification that the tree has fully loaded (the previous root node reference | |
1113 * will stop working at or before this point). | |
1114 * @param {number} tabId | |
1115 * @param {function(!chrome.automation.AutomationNode):void} callback Called | |
1116 * when the <code>AutomationNode</code> for the page is available. | |
1117 * @see https://developer.chrome.com/extensions/automation#method-getTree | |
1118 */ | |
1119 chrome.automation.getTree = function(tabId, callback) {}; | |
1120 | |
1121 /** | |
1122 * Get the automation tree for the whole desktop which consists of all on screen | |
1123 * views. Note this API is currently only supported on Chrome OS. | |
1124 * @param {function(!chrome.automation.AutomationNode):void} callback Called | |
1125 * when the <code>AutomationNode</code> for the page is available. | |
1126 * @see https://developer.chrome.com/extensions/automation#method-getDesktop | |
1127 */ | |
1128 chrome.automation.getDesktop = function(callback) {}; | |
1129 | |
1130 /** | |
1131 * Get the automation node that currently has focus, globally. Will return null | |
1132 * if none of the nodes in any loaded trees have focus. | |
1133 * @param {function(!chrome.automation.AutomationNode):void} callback Called | |
1134 * with the <code>AutomationNode</code> that currently has focus. | |
1135 * @see https://developer.chrome.com/extensions/automation#method-getFocus | |
1136 */ | |
1137 chrome.automation.getFocus = function(callback) {}; | |
1138 | |
1139 /** | |
1140 * Add a tree change observer. Tree change observers are static/global, they | |
1141 * listen to changes across all trees. Pass a filter to determine what specific | |
1142 * tree changes to listen to, and note that listnening to all tree changes can | |
1143 * be expensive. | |
1144 * @param {!chrome.automation.TreeChangeObserverFilter} filter | |
1145 * @param {function(!chrome.automation.TreeChange):void} observer A listener for | |
1146 * changes on the <code>AutomationNode</code> tree. | |
1147 * @see https://developer.chrome.com/extensions/automation#method-addTreeChangeO
bserver | |
1148 */ | |
1149 chrome.automation.addTreeChangeObserver = function(filter, observer) {}; | |
1150 | |
1151 /** | |
1152 * Remove a tree change observer. | |
1153 * @param {function(!chrome.automation.TreeChange):void} observer A listener for | |
1154 * changes on the <code>AutomationNode</code> tree. | |
1155 * @see https://developer.chrome.com/extensions/automation#method-removeTreeChan
geObserver | |
1156 */ | |
1157 chrome.automation.removeTreeChangeObserver = function(observer) {}; | |
1158 | |
1159 /** | |
1160 * Sets the selection in a tree. This creates a selection in a single tree | |
1161 * (anchorObject and focusObject must have the same root). Everything in the | |
1162 * tree between the two node/offset pairs gets included in the selection. The | |
1163 * anchor is where the user started the selection, while the focus is the point | |
1164 * at which the selection gets extended e.g. when dragging with a mouse or using | |
1165 * the keyboard. For nodes with the role staticText, the offset gives the | |
1166 * character offset within the value where the selection starts or ends, | |
1167 * respectively. | |
1168 * @param {!chrome.automation.SetDocumentSelectionParams} params | |
1169 * @see https://developer.chrome.com/extensions/automation#method-setDocumentSel
ection | |
1170 */ | |
1171 chrome.automation.setDocumentSelection = function(params) {}; | |
OLD | NEW |