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

Unified Diff: chrome/browser/speech/tts_linux.cc

Issue 1043933002: Support languages other than the default on linux (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix build error Created 5 years, 8 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
« no previous file with comments | « build/linux/system.gyp ('k') | third_party/speech-dispatcher/BUILD.gn » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/speech/tts_linux.cc
diff --git a/chrome/browser/speech/tts_linux.cc b/chrome/browser/speech/tts_linux.cc
index 2f29236a8f6cff39b9655524c4d8b68a0f17965f..1ede2b3d22035409cdff7c6467181a1c4a7a1239 100644
--- a/chrome/browser/speech/tts_linux.cc
+++ b/chrome/browser/speech/tts_linux.cc
@@ -192,6 +192,10 @@ bool TtsPlatformImplLinux::Speak(
libspeechd_loader_.spd_set_voice_rate(conn_, 100 * log10(rate) / log10(3));
libspeechd_loader_.spd_set_voice_pitch(conn_, 100 * log10(pitch) / log10(3));
+ // Support languages other than the default
+ if (!lang.empty())
+ libspeechd_loader_.spd_set_language(conn_, lang.c_str());
+
utterance_ = utterance;
utterance_id_ = utterance_id;
« no previous file with comments | « build/linux/system.gyp ('k') | third_party/speech-dispatcher/BUILD.gn » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698