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

Side by Side Diff: chrome/browser/resources/chromeos/chromevox/cvox2/background/output.js

Issue 2438893004: Revert of Make ChromeVox Next the default ChromeVox experience (Closed)
Patch Set: Created 4 years, 2 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 unified diff | Download patch
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 /** 5 /**
6 * @fileoverview Provides output services for ChromeVox. 6 * @fileoverview Provides output services for ChromeVox.
7 */ 7 */
8 8
9 goog.provide('Output'); 9 goog.provide('Output');
10 goog.provide('Output.EventType'); 10 goog.provide('Output.EventType');
(...skipping 976 matching lines...) Expand 10 before | Expand all | Expand 10 after
987 if (prevRange && !prevRange.isValid()) 987 if (prevRange && !prevRange.isValid())
988 prevRange = null; 988 prevRange = null;
989 989
990 // Scan unique ancestors to get the value of |outputContextFirst|. 990 // Scan unique ancestors to get the value of |outputContextFirst|.
991 var parent = range.start.node; 991 var parent = range.start.node;
992 var prevParent = prevRange ? prevRange.start.node : parent; 992 var prevParent = prevRange ? prevRange.start.node : parent;
993 if (!parent || !prevParent) 993 if (!parent || !prevParent)
994 return; 994 return;
995 var uniqueAncestors = AutomationUtil.getUniqueAncestors(prevParent, parent); 995 var uniqueAncestors = AutomationUtil.getUniqueAncestors(prevParent, parent);
996 for (var i = 0; parent = uniqueAncestors[i]; i++) { 996 for (var i = 0; parent = uniqueAncestors[i]; i++) {
997 if (parent.role == RoleType.window)
998 break;
999 if (Output.ROLE_INFO_[parent.role] && 997 if (Output.ROLE_INFO_[parent.role] &&
1000 Output.ROLE_INFO_[parent.role].outputContextFirst) { 998 Output.ROLE_INFO_[parent.role].outputContextFirst) {
1001 this.outputContextFirst_ = true; 999 this.outputContextFirst_ = true;
1002 break; 1000 break;
1003 } 1001 }
1004 } 1002 }
1005 1003
1006 if (range.isSubNode()) 1004 if (range.isSubNode())
1007 this.subNode_(range, prevRange, type, buff); 1005 this.subNode_(range, prevRange, type, buff);
1008 else 1006 else
(...skipping 762 matching lines...) Expand 10 before | Expand all | Expand 10 after
1771 /** 1769 /**
1772 * Gets the output buffer for braille. 1770 * Gets the output buffer for braille.
1773 * @return {!Spannable} 1771 * @return {!Spannable}
1774 */ 1772 */
1775 get brailleOutputForTest() { 1773 get brailleOutputForTest() {
1776 return this.createBrailleOutput_(); 1774 return this.createBrailleOutput_();
1777 } 1775 }
1778 }; 1776 };
1779 1777
1780 }); // goog.scope 1778 }); // goog.scope
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698