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

Unified Diff: chrome/browser/resources/chromeos/chromevox/cvox2/background/automation_util.js

Issue 908853004: Revert of Reland #2: Ensure WebView notifies desktop automation on creation, destruction, and change Original (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 10 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
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

Powered by Google App Engine
This is Rietveld 408576698