Merge "Show current locale as summary for Select language setting."
diff --git a/src/com/android/settings/TextToSpeechSettings.java b/src/com/android/settings/TextToSpeechSettings.java
index 86f9919..3c55d10 100644
--- a/src/com/android/settings/TextToSpeechSettings.java
+++ b/src/com/android/settings/TextToSpeechSettings.java
@@ -265,9 +265,15 @@
if (status == TextToSpeech.SUCCESS) {
Log.v(TAG, "TTS engine for settings screen initialized.");
mEnableDemo = true;
- if (mDefaultLanguage == null){
+ if (mDefaultLanguage == null) {
mDefaultLanguage = Locale.getDefault().getISO3Language();
}
+ if (mDefaultCountry == null) {
+ mDefaultCountry = Locale.getDefault().getISO3Country();
+ }
+ if (mDefaultLocVariant == null) {
+ mDefaultLocVariant = new String();
+ }
mTts.setLanguage(new Locale(mDefaultLanguage, mDefaultCountry, mDefaultLocVariant));
mTts.setSpeechRate((float)(mDefaultRate/100.0f));
} else {