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

Unified Diff: chrome/browser/resources/chromeos/chromevox/host/chrome/tts_background.js

Issue 2563013003: Support audio ducking and suspension in ChromeVox (Closed)
Patch Set: Fix compile. Created 4 years 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/host/chrome/tts_background.js
diff --git a/chrome/browser/resources/chromeos/chromevox/host/chrome/tts_background.js b/chrome/browser/resources/chromeos/chromevox/host/chrome/tts_background.js
index d4d37045800bd407ec89f329b594cc5db0819ec2..d07d2ff668d141c74e2df3fbc0f6cab4553dcbae 100644
--- a/chrome/browser/resources/chromeos/chromevox/host/chrome/tts_background.js
+++ b/chrome/browser/resources/chromeos/chromevox/host/chrome/tts_background.js
@@ -414,6 +414,9 @@ cvox.TtsBackground.prototype.onTtsEvent_ = function(event, utteranceId) {
this.cancelUtterance_(this.utteranceQueue_[i]);
}
this.utteranceQueue_.length = 0;
+ this.capturingTtsEventListeners_.forEach(function(listener) {
+ listener.onTtsInterrupted();
+ });
break;
case 'error':
this.onError_(event['errorMessage']);
@@ -498,6 +501,10 @@ cvox.TtsBackground.prototype.stop = function() {
(new PanelCommand(PanelCommandType.CLEAR_SPEECH)).send();
chrome.tts.stop();
+
+ this.capturingTtsEventListeners_.forEach(function(listener) {
+ listener.onTtsInterrupted();
+ });
};
/** @override */

Powered by Google App Engine
This is Rietveld 408576698