From 646d950ed8d2b2555df92855e18b350fd7761b21 Mon Sep 17 00:00:00 2001 From: Jean Chalard Date: Thu, 14 Apr 2011 20:45:47 +0900 Subject: Receive a broadcast that the dictionary has been updated. Change-Id: I9751cc627a835a4061f144c48ff51e9d81b2c93b --- .../inputmethod/latin/DictionaryPackInstallBroadcastReceiver.java | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'java/src/com/android/inputmethod/latin/DictionaryPackInstallBroadcastReceiver.java') diff --git a/java/src/com/android/inputmethod/latin/DictionaryPackInstallBroadcastReceiver.java b/java/src/com/android/inputmethod/latin/DictionaryPackInstallBroadcastReceiver.java index c7864621d..9d30af84b 100644 --- a/java/src/com/android/inputmethod/latin/DictionaryPackInstallBroadcastReceiver.java +++ b/java/src/com/android/inputmethod/latin/DictionaryPackInstallBroadcastReceiver.java @@ -30,6 +30,11 @@ import android.net.Uri; public class DictionaryPackInstallBroadcastReceiver extends BroadcastReceiver { final LatinIME mService; + /** + * The action of the intent for publishing that new dictionary data is available. + */ + /* package */ static final String NEW_DICTIONARY_INTENT_ACTION = + "com.android.inputmethod.latin.dictionarypack.newdict"; public DictionaryPackInstallBroadcastReceiver(final LatinIME service) { mService = service; @@ -77,6 +82,8 @@ public class DictionaryPackInstallBroadcastReceiver extends BroadcastReceiver { // TODO: Only reload dictionary on REMOVED when the removed package is the one we // read dictionary from? mService.resetSuggestMainDict(); + } else if (action.equals(NEW_DICTIONARY_INTENT_ACTION)) { + mService.resetSuggestMainDict(); } } } -- cgit v1.2.3-83-g751a