| Index: chrome/browser/resources/chromeos/chromevox/cvox2/background/desktop_automation_handler.js
|
| diff --git a/chrome/browser/resources/chromeos/chromevox/cvox2/background/desktop_automation_handler.js b/chrome/browser/resources/chromeos/chromevox/cvox2/background/desktop_automation_handler.js
|
| index 10a137fa37173347b357f008b890a62f4bc090f6..c26ebddbabc9f639c54b5c6353c6a1bc4ed7dbd3 100644
|
| --- a/chrome/browser/resources/chromeos/chromevox/cvox2/background/desktop_automation_handler.js
|
| +++ b/chrome/browser/resources/chromeos/chromevox/cvox2/background/desktop_automation_handler.js
|
| @@ -53,7 +53,7 @@ DesktopAutomationHandler = function(node) {
|
| this.addListener_(e.menuListItemSelected, this.onEventIfSelected);
|
| this.addListener_(e.menuStart, this.onMenuStart);
|
| this.addListener_(e.scrollPositionChanged, this.onScrollPositionChanged);
|
| - this.addListener_(e.selection, this.onEventWithFlushedOutput);
|
| + this.addListener_(e.selection, this.onSelection);
|
| this.addListener_(e.textChanged, this.onTextChanged);
|
| this.addListener_(e.textSelectionChanged, this.onTextSelectionChanged);
|
| this.addListener_(e.valueChanged, this.onValueChanged);
|
| @@ -245,8 +245,7 @@ DesktopAutomationHandler.prototype = {
|
| }).bind(this));
|
| },
|
|
|
| -
|
| - /**
|
| + /**
|
| * Provides all feedback once a text changed event fires.
|
| * @param {!AutomationEvent} evt
|
| */
|
| @@ -337,6 +336,17 @@ DesktopAutomationHandler.prototype = {
|
| },
|
|
|
| /**
|
| + * @param {!AutomationEvent} evt
|
| + */
|
| + onSelection: function(evt) {
|
| + chrome.automation.getFocus(function(focus) {
|
| + if (!AutomationUtil.isDescendantOf(evt.target, focus))
|
| + return;
|
| + this.onEventDefault(evt);
|
| + }.bind(this));
|
| + },
|
| +
|
| + /**
|
| * Provides all feedback once a menu start event fires.
|
| * @param {!AutomationEvent} evt
|
| */
|
|
|