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

Unified Diff: chrome/common/extensions/api/automation.idl

Issue 1198613002: Revert of Reimplement automation API on top of C++-backed AXTree. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@automation_faster_2
Patch Set: Created 5 years, 6 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_browser_extensions.gypi ('k') | chrome/common/extensions/api/automation_internal.idl » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/common/extensions/api/automation.idl
diff --git a/chrome/common/extensions/api/automation.idl b/chrome/common/extensions/api/automation.idl
index 426163e1b62dc2758f8087600f8db0b3fa739444..a0d81168b5847bed4c67be3f2c885a7fb1ded784 100644
--- a/chrome/common/extensions/api/automation.idl
+++ b/chrome/common/extensions/api/automation.idl
@@ -317,6 +317,8 @@
// The role of this node.
automation.RoleType role;
+ // TODO(aboxhall): expose states as mixins instead
+
// The $(ref:automation.StateType)s describing this node.
object state;
@@ -367,101 +369,18 @@
// name, via the $(ref:automation.AutomationNode.name) attribute.
AutomationNode[] labelledBy;
- // The node referred to by <code>aria-activedescendant</code>, where
- // applicable
- AutomationNode activedescendant;
-
- //
- // Link attributes.
- //
-
- // The URL that this link will navigate to.
- DOMString url;
-
- //
- // Document attributes.
- //
-
- // The URL of this document.
- DOMString docUrl;
-
- // The title of this document.
- DOMString docTitle;
-
- // Whether this document has finished loading.
- boolean docLoaded;
-
- // The proportion (out of 1.0) that this doc has completed loading.
- double docLoadingProgress;
-
- //
- // Scrollable container attributes.
- //
-
- long scrollX;
- long scrollXMin;
- long scrollXMax;
- long scrollY;
- long scrollYMin;
- long scrollYMax;
-
- //
- // Editable text field attributes.
- //
-
- // The character index of the start of the selection within this editable
- // text element; -1 if no selection.
- long textSelStart;
-
- // The character index of the end of the selection within this editable
- // text element; -1 if no selection.
- long textSelEnd;
-
- // The input type, like email or number.
- DOMString textInputType;
-
- //
- // Range attributes.
- //
-
- // The current value for this range.
- double valueForRange;
-
- // The minimum possible value for this range.
- double minValueForRange;
-
- // The maximum possible value for this range.
- double maxValueForRange;
-
- //
- // Table attributes.
- //
-
- // The number of rows in this table.
- long tableRowCount;
-
- // The number of columns in this table.
- long tableColumnCount;
-
- //
- // Table cell attributes.
- //
-
- // The zero-based index of the column that this cell is in.
- long tableCellColumnIndex;
-
- // The number of columns that this cell spans (default is 1).
- long tableCellColumnSpan;
-
- // The zero-based index of the row that this cell is in.
- long tableCellRowIndex;
-
- // The number of rows that this cell spans (default is 1).
- long tableCellRowSpan;
-
- //
- // Walking the tree.
- //
+ // The nodes, if any, which are to be considered children of this node but
+ // are not children in the DOM tree.
+ AutomationNode[] owns;
+
+ // TODO(aboxhall): Make this private?
+
+ // A collection of this node's other attributes.
+ object? attributes;
+
+ // 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;
AutomationNode[] children;
AutomationNode parent;
@@ -470,14 +389,6 @@
AutomationNode previousSibling;
AutomationNode nextSibling;
- // 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;
-
- //
- // Actions.
- //
-
// Does the default action based on this node's role. This is generally
// the same action that would result from clicking the node such as
// expanding a treeitem, toggling a checkbox, selecting a radiobutton,
@@ -492,6 +403,9 @@
// Sets selection within a text field.
static void setSelection(long startIndex, long endIndex);
+
+ // Shows the context menu resulting from a right click on this node.
+ static void showContextMenu();
// Adds a listener for the given event type and event phase.
static void addEventListener(
@@ -529,6 +443,100 @@
static boolean matches(FindParams params);
};
+ dictionary ActiveDescendantMixin {
+ // The node referred to by <code>aria-activedescendant</code>, where
+ // applicable
+ AutomationNode activedescendant;
+ };
+
+ // Attributes which are mixed in to an AutomationNode if it is a link.
+ dictionary LinkMixins {
+ // TODO(aboxhall): Add visited state
+
+ // The URL that this link will navigate to.
+ DOMString url;
+ };
+
+ // Attributes which are mixed in to an AutomationNode if it is a document.
+ dictionary DocumentMixins {
+ // The URL of this document.
+ DOMString docUrl;
+
+ // The title of this document.
+ DOMString docTitle;
+
+ // Whether this document has finished loading.
+ boolean docLoaded;
+
+ // The proportion (out of 1.0) that this doc has completed loading.
+ double docLoadingProgress;
+ };
+
+ // TODO(aboxhall): document ScrollableMixins (e.g. what is scrollXMin? is it
+ // ever not 0?)
+
+ // Attributes which are mixed in to an AutomationNode if it is scrollable.
+ dictionary ScrollableMixins {
+ long scrollX;
+ long scrollXMin;
+ long scrollXMax;
+ long scrollY;
+ long scrollYMin;
+ long scrollYMax;
+ };
+
+ // Attributes which are mixed in to an AutomationNode if it is editable text.
+ dictionary EditableTextMixins {
+ // The character index of the start of the selection within this editable
+ // text element; -1 if no selection.
+ long textSelStart;
+
+ // The character index of the end of the selection within this editable
+ // text element; -1 if no selection.
+ long textSelEnd;
+
+ // The input type, like email or number.
+ DOMString textInputType;
+ };
+
+ // Attributes which are mixed in to an AutomationNode if it is a range.
+ dictionary RangeMixins {
+ // The current value for this range.
+ double valueForRange;
+
+ // The minimum possible value for this range.
+ double minValueForRange;
+
+ // The maximum possible value for this range.
+ double maxValueForRange;
+ };
+
+ // TODO(aboxhall): live region mixins.
+
+ // Attributes which are mixed in to an AutomationNode if it is a table.
+ dictionary TableMixins {
+ // The number of rows in this table.
+ long tableRowCount;
+
+ // The number of columns in this table.
+ long tableColumnCount;
+ };
+
+ // Attributes which are mixed in to an AutomationNode if it is a table cell.
+ dictionary TableCellMixins {
+ // The zero-based index of the column that this cell is in.
+ long tableCellColumnIndex;
+
+ // The number of columns that this cell spans (default is 1).
+ long tableCellColumnSpan;
+
+ // The zero-based index of the row that this cell is in.
+ long tableCellRowIndex;
+
+ // The number of rows that this cell spans (default is 1).
+ long tableCellRowSpan;
+ };
+
// Called when the <code>AutomationNode</code> for the page is available.
callback RootCallback = void(AutomationNode rootNode);
« no previous file with comments | « chrome/chrome_browser_extensions.gypi ('k') | chrome/common/extensions/api/automation_internal.idl » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698