aboutsummaryrefslogtreecommitdiffstats
path: root/java/src/com/android/inputmethod/latin/SystemBroadcastReceiver.java
diff options
context:
space:
mode:
authorDan Zivkovic <zivkovic@google.com>2015-05-21 08:58:36 -0700
committerDan Zivkovic <zivkovic@google.com>2015-05-21 10:24:15 -0700
commit7891733c73245bddf0a53f150187fa9fc3f97866 (patch)
tree3d44c88ba62336aefe44a0093b21b7a8219c5cac /java/src/com/android/inputmethod/latin/SystemBroadcastReceiver.java
parent0e15ff6b48adfe5d2ff8ac988314f3d5eaaa43de (diff)
downloadlatinime-7891733c73245bddf0a53f150187fa9fc3f97866.tar.gz
latinime-7891733c73245bddf0a53f150187fa9fc3f97866.tar.xz
latinime-7891733c73245bddf0a53f150187fa9fc3f97866.zip
Remove dogfood history reset.
Change-Id: I1d7ebe5962fc3176c376e1ce34c7ac98cdf41373
Diffstat (limited to 'java/src/com/android/inputmethod/latin/SystemBroadcastReceiver.java')
-rw-r--r--java/src/com/android/inputmethod/latin/SystemBroadcastReceiver.java33
1 files changed, 0 insertions, 33 deletions
diff --git a/java/src/com/android/inputmethod/latin/SystemBroadcastReceiver.java b/java/src/com/android/inputmethod/latin/SystemBroadcastReceiver.java
index 0d1853bc4..d37f70b42 100644
--- a/java/src/com/android/inputmethod/latin/SystemBroadcastReceiver.java
+++ b/java/src/com/android/inputmethod/latin/SystemBroadcastReceiver.java
@@ -16,10 +16,8 @@
package com.android.inputmethod.latin;
-import android.accounts.Account;
import android.content.BroadcastReceiver;
import android.content.ComponentName;
-import android.content.ContentResolver;
import android.content.Context;
import android.content.Intent;
import android.content.SharedPreferences;
@@ -33,14 +31,10 @@ import android.view.inputmethod.InputMethodSubtype;
import com.android.inputmethod.dictionarypack.DictionaryPackConstants;
import com.android.inputmethod.keyboard.KeyboardLayoutSet;
-import com.android.inputmethod.latin.settings.LocalSettingsConstants;
-import com.android.inputmethod.latin.accounts.LoginAccountUtils;
import com.android.inputmethod.latin.settings.Settings;
import com.android.inputmethod.latin.setup.SetupActivity;
import com.android.inputmethod.latin.utils.UncachedInputMethodManagerUtils;
-import java.util.Locale;
-
/**
* This class detects the {@link Intent#ACTION_MY_PACKAGE_REPLACED} broadcast intent when this IME
* package has been replaced by a newer version of the same package. This class also detects
@@ -81,33 +75,6 @@ public final class SystemBroadcastReceiver extends BroadcastReceiver {
richImm.setAdditionalInputMethodSubtypes(additionalSubtypes);
toggleAppIcon(context);
downloadLatestDictionaries(context);
- ////////////////////////////////////////////////////////////////////////////
- // TODO: This is only for dogfood builds. Remove this from the final release.
- DictionaryFacilitator keyboardFacilitator =
- DictionaryFacilitatorProvider.getDictionaryFacilitator(false);
- boolean historyCleared = keyboardFacilitator.clearUserHistoryDictionary(context);
- Locale keyboardLocale = keyboardFacilitator.getLocale();
- if (historyCleared && keyboardLocale != null) {
- keyboardFacilitator.resetDictionaries(
- context,
- keyboardLocale,
- keyboardFacilitator.usesContacts(),
- true /* history */,
- true /* force */,
- keyboardFacilitator.getAccount(),
- "" /* prefix */,
- null /* listener */);
- }
- final SharedPreferences prefs = PreferenceManager.getDefaultSharedPreferences(context);
- final String syncAccount = prefs.getString(
- LocalSettingsConstants.PREF_ACCOUNT_NAME, null /* default */);
- if (syncAccount != null) {
- ContentResolver.setSyncAutomatically(
- new Account(syncAccount, LoginAccountUtils.ACCOUNT_TYPE),
- "com.android.inputmethod.latin.provider",
- true);
- }
- ////////////////////////////////////////////////////////////////////////////
} else if (Intent.ACTION_BOOT_COMPLETED.equals(intentAction)) {
Log.i(TAG, "Boot has been completed");
toggleAppIcon(context);