Chromium Code Reviews| Index: chrome/common/extensions/api/automation.idl |
| diff --git a/chrome/common/extensions/api/automation.idl b/chrome/common/extensions/api/automation.idl |
| index 2c48253a86f695ee4cf2d8bf473f5cb6924041dc..584c7c4232e27645cb367313dff6af81f6ce9c10 100644 |
| --- a/chrome/common/extensions/api/automation.idl |
| +++ b/chrome/common/extensions/api/automation.idl |
| @@ -236,12 +236,15 @@ |
| // A listener for events on an <code>AutomationNode</code>. |
| callback AutomationListener = void(AutomationEvent event); |
| + // Called when the root <code>AutomationNode</code> for the page is available. |
| + callback RootCallback = void(AutomationNode rootNode); |
| + |
| // A single node in an Automation tree. |
| [nocompile, noinline_doc] dictionary AutomationNode { |
| // The root node of the tree containing this AutomationNode. |
| - AutomationRootNode root; |
| + AutomationNode root; |
|
aboxhall
2014/10/29 19:29:11
Why did this change? An AutomationRootNode _is_ an
David Tseng
2014/10/29 20:35:30
I removed the AutomationRootNode interface; can pu
|
| - // Whether this AutomationNode is an AutomationRootNode. |
| + // Whether this AutomationNode is a root node. |
| boolean isRootNode; |
| // Unique ID to identify this node. |
| @@ -259,6 +262,10 @@ |
| // A collection of this node's other attributes. |
| object? attributes; |
| + // Whether this AutomationNode is loaded or not. If false, call load() |
| + // to get the contents. Only applicable on webArea nodes. |
| + boolean? loaded; |
| + |
| // The index of this node in its parent node's list of children. If this is |
| // the root node, this will be undefined. |
| long? indexInParent; |
| @@ -285,6 +292,10 @@ |
| // Sets selection within a text field. |
| static void setSelection(long startIndex, long endIndex); |
| + // Load the accessibility tree for this node hosting a frame. Only |
| + // applicable on webArea nodes. |
| + static void load(RootCallback callback); |
| + |
| // Adds a listener for the given event type and event phase. |
| static void addEventListener( |
| EventType eventType, AutomationListener listener, boolean capture); |
| @@ -294,36 +305,6 @@ |
| EventType eventType, AutomationListener listener, boolean capture); |
| }; |
| - // Called when the <code>AutomationRootNode</code> for the page is available. |
| - callback RootCallback = void(AutomationRootNode rootNode); |
| - |
| - // The root node of the automation tree for a single frame or desktop. |
| - // This may be: |
| - // <ul> |
| - // <li> The desktop |
| - // <li> The top frame of a page |
| - // <li> A frame or iframe within a page |
| - // </ul> |
| - // Thus, an <code>AutomationRootNode</code> may be a descendant of one or |
| - // more <code>AutomationRootNode</code>s, and in turn have one or more |
| - // <code>AutomationRootNode</code>s in its descendants. Thus, the |
| - // <code>root</code> property of the <code>AutomationRootNode</code> will be |
| - // the immediate parent <code>AutomationRootNode</code>, or <code>null</code> |
| - // if this is the top-level <code>AutomationRootNode</code>. |
| - // |
| - // Extends $(ref:automation.AutomationNode). |
| - [nocompile, noinline_doc] dictionary AutomationRootNode { |
| - // TODO(aboxhall/dtseng): implement loading. Kept separate to not include |
| - // in generated docs. |
| - |
| - // Whether this AutomationRootNode is loaded or not. If false, call load() |
| - // to get the contents. |
| - boolean loaded; |
| - |
| - // Load the accessibility tree for this AutomationRootNode. |
| - static void load(RootCallback callback); |
| - }; |
| - |
| interface Functions { |
| // Get the automation tree for the tab with the given tabId, or the current |
| // tab if no tabID is given, enabling automation if necessary. Returns a |