| Index: chrome/browser/resources/chromeos/chromevox/cvox2/background/keyboard_handler.js
|
| diff --git a/chrome/browser/resources/chromeos/chromevox/cvox2/background/keyboard_handler.js b/chrome/browser/resources/chromeos/chromevox/cvox2/background/keyboard_handler.js
|
| index 8d4990f33f33e159adff7918c48b22f46f78dc87..2f3505ff4d343bc2242b372446e1556c182eabdd 100644
|
| --- a/chrome/browser/resources/chromeos/chromevox/cvox2/background/keyboard_handler.js
|
| +++ b/chrome/browser/resources/chromeos/chromevox/cvox2/background/keyboard_handler.js
|
| @@ -18,6 +18,9 @@ BackgroundKeyboardHandler = function() {
|
| /** @type {number} @private */
|
| this.passThroughKeyUpCount_ = 0;
|
|
|
| + /** @type {Set} @private */
|
| + this.eatenKeyDowns_ = new Set();
|
| +
|
| document.addEventListener('keydown', this.onKeyDown.bind(this), false);
|
| document.addEventListener('keyup', this.onKeyUp.bind(this), false);
|
| };
|
| @@ -38,6 +41,7 @@ BackgroundKeyboardHandler.prototype = {
|
| !cvox.ChromeVoxKbHandler.basicKeyDownActionsListener(evt)) {
|
| evt.preventDefault();
|
| evt.stopPropagation();
|
| + this.eatenKeyDowns_.add(evt.keyCode);
|
| }
|
| Output.forceModeForNextSpeechUtterance(cvox.QueueMode.FLUSH);
|
| return false;
|
| @@ -59,6 +63,13 @@ BackgroundKeyboardHandler.prototype = {
|
| this.passThroughKeyUpCount_++;
|
| }
|
| }
|
| +
|
| + if (this.eatenKeyDowns_.has(evt.keyCode)) {
|
| + evt.preventDefault();
|
| + evt.stopPropagation();
|
| + this.eatenKeyDowns_.delete(evt.keyCode);
|
| + }
|
| +
|
| return false;
|
| },
|
|
|
|
|