Index: ui/android/java/src/org/chromium/ui/AXNodeData.java |
diff --git a/ui/android/java/src/org/chromium/ui/AXNodeData.java b/ui/android/java/src/org/chromium/ui/AXNodeData.java |
new file mode 100644 |
index 0000000000000000000000000000000000000000..9030df4224dddc2ffbee81ed4868fe9769ad8d13 |
--- /dev/null |
+++ b/ui/android/java/src/org/chromium/ui/AXNodeData.java |
@@ -0,0 +1,37 @@ |
+// Copyright 2015 The Chromium Authors. All rights reserved. |
+// Use of this source code is governed by a BSD-style license that can be |
+// found in the LICENSE file. |
+ |
+package org.chromium.ui; |
+ |
+import java.util.ArrayList; |
+ |
+/** |
+ * A data struct to convey AXNodeData information to Java side. |
dmazzoni
2015/04/10 19:20:00
I think we should convey how this differs from sim
sgurun-gerrit only
2015/04/10 23:24:50
That is a very clear description. Thanks!
|
+ */ |
+public class AXNodeData { |
dmazzoni
2015/04/10 19:20:00
It feels like this is the wrong level of abstracti
sgurun-gerrit only
2015/04/10 23:24:50
Done.
|
+ |
+ public int id; |
+ public int x, y, scrollX, scrollY, width, height; |
+ public int childCount; |
+ public String text; |
+ public String className; |
+ public ArrayList<AXNodeData> children = new ArrayList<AXNodeData>(); |
+ |
+ public AXNodeData(int id, int x, int y, int scrollX, int scrollY, int width, int height, |
+ String text, String className) { |
+ this.id = id; |
+ this.x = x; |
+ this.y = y; |
+ this.scrollX = scrollX; |
+ this.scrollY = scrollY; |
+ this.width = width; |
+ this.height = height; |
+ this.text = text; |
+ this.className = className; |
+ } |
+ |
+ public void addChild(AXNodeData node) { |
+ children.add(node); |
+ } |
+} |