Index: chrome/browser/resources/chromeos/chromevox/cvox2/background/automation_util.js |
diff --git a/chrome/browser/resources/chromeos/chromevox/cvox2/background/automation_util.js b/chrome/browser/resources/chromeos/chromevox/cvox2/background/automation_util.js |
index 16f7506bb8105264199e695126d823c3a9de0ab6..d5d9956f345141a1a4dd2edde5f88132d37f01f4 100644 |
--- a/chrome/browser/resources/chromeos/chromevox/cvox2/background/automation_util.js |
+++ b/chrome/browser/resources/chromeos/chromevox/cvox2/background/automation_util.js |
@@ -88,12 +88,8 @@ |
while (cur) { |
var next = dir == Dir.BACKWARD ? |
cur.previousSibling : cur.nextSibling; |
- if (!AutomationUtil.isInSameTree(cur, next)) |
- return null; |
if (next) |
return next; |
- if (!AutomationUtil.isInSameTree(cur, cur.parent)) |
- return null; |
cur = cur.parent; |
} |
}; |
@@ -168,10 +164,6 @@ |
var candidate = node; |
while (candidate) { |
ret.push(candidate); |
- |
- if (!AutomationUtil.isInSameTree(candidate, candidate.parent)) |
- break; |
- |
candidate = candidate.parent; |
} |
return ret.reverse(); |
@@ -234,17 +226,4 @@ |
return divA.indexInParent <= divB.indexInParent ? Dir.FORWARD : Dir.BACKWARD; |
}; |
-/** |
- * Determines whether the two given nodes come from the same tree source. |
- * @param {AutomationNode} a |
- * @param {AutomationNode} b |
- * @return {boolean} |
- */ |
-AutomationUtil.isInSameTree = function(a, b) { |
- if (!a || !b) |
- return true; |
- |
- return a.root === b.root; |
-}; |
- |
}); // goog.scope |