From 8f4eb4d74bb5c15bb7576f02f1c5e0611beb881a Mon Sep 17 00:00:00 2001 From: Salvador Martinez Date: Wed, 17 Aug 2016 11:53:14 -0700 Subject: [PATCH] Can restore state on rotate personal dict screen When adding/editing a word for your personal dictionary rotating the screen could cause the language to change back to the device default. This has been fixed. Test: ag/1389633, robolectric not supported in this branch. Bug: 30874931 Change-Id: I0c8ebec5f4d5e7b23112b656c482c3b2cda7791f --- .../settings/inputmethod/UserDictionaryAddWordContents.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/com/android/settings/inputmethod/UserDictionaryAddWordContents.java b/src/com/android/settings/inputmethod/UserDictionaryAddWordContents.java index 638818a75c6..98c4db2ea47 100644 --- a/src/com/android/settings/inputmethod/UserDictionaryAddWordContents.java +++ b/src/com/android/settings/inputmethod/UserDictionaryAddWordContents.java @@ -87,7 +87,7 @@ public class UserDictionaryAddWordContents { mMode = MODE_EDIT; mOldWord = oldInstanceToBeEdited.mSavedWord; mOldShortcut = oldInstanceToBeEdited.mSavedShortcut; - updateLocale(mLocale); + updateLocale(oldInstanceToBeEdited.getCurrentUserDictionaryLocale()); } // locale may be null, this means default locale