From d567b230b055cb69186acf1ce0a1c4e1c7b61508 Mon Sep 17 00:00:00 2001 From: Jean Chalard Date: Mon, 12 Dec 2011 19:52:17 +0900 Subject: [PATCH] Move a settings var to the settings class Change-Id: I1331ad6dec3a9d64a77e314f8a1f4c29282df31b --- java/src/com/android/inputmethod/latin/LatinIME.java | 3 +-- java/src/com/android/inputmethod/latin/SettingsValues.java | 2 ++ 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/java/src/com/android/inputmethod/latin/LatinIME.java b/java/src/com/android/inputmethod/latin/LatinIME.java index 711afdfdd..d4aab409f 100644 --- a/java/src/com/android/inputmethod/latin/LatinIME.java +++ b/java/src/com/android/inputmethod/latin/LatinIME.java @@ -1086,8 +1086,7 @@ public class LatinIME extends InputMethodServiceCompatWrapper implements Keyboar @Override public boolean onEvaluateFullscreenMode() { - return super.onEvaluateFullscreenMode() - && mResources.getBoolean(R.bool.config_use_fullscreen_mode); + return super.onEvaluateFullscreenMode() && mSettingsValues.mUseFullScreenMode; } @Override diff --git a/java/src/com/android/inputmethod/latin/SettingsValues.java b/java/src/com/android/inputmethod/latin/SettingsValues.java index a3fe15dc6..0ad1c1529 100644 --- a/java/src/com/android/inputmethod/latin/SettingsValues.java +++ b/java/src/com/android/inputmethod/latin/SettingsValues.java @@ -41,6 +41,7 @@ public class SettingsValues { private final String mSymbolsExcludedFromWordSeparators; public final String mWordSeparators; public final CharSequence mHintToSaveText; + public final boolean mUseFullScreenMode; // From preferences, in the same order as xml/prefs.xml: public final boolean mAutoCap; @@ -94,6 +95,7 @@ public class SettingsValues { mWordSeparators = createWordSeparators(mMagicSpaceStrippers, mMagicSpaceSwappers, mSymbolsExcludedFromWordSeparators, res); mHintToSaveText = context.getText(R.string.hint_add_to_dictionary); + mUseFullScreenMode = res.getBoolean(R.bool.config_use_fullscreen_mode); // Get the settings preferences mAutoCap = prefs.getBoolean(Settings.PREF_AUTO_CAP, true);