Merge "Reorder members in SettingsValues."
This commit is contained in:
commit
f8a056c5c8
2 changed files with 34 additions and 33 deletions
|
@ -58,42 +58,37 @@ public class Settings extends InputMethodSettingsActivity
|
||||||
|
|
||||||
public static final boolean ENABLE_EXPERIMENTAL_SETTINGS = false;
|
public static final boolean ENABLE_EXPERIMENTAL_SETTINGS = false;
|
||||||
|
|
||||||
|
// In the same order as xml/prefs.xml
|
||||||
public static final String PREF_GENERAL_SETTINGS_KEY = "general_settings";
|
public static final String PREF_GENERAL_SETTINGS_KEY = "general_settings";
|
||||||
|
public static final String PREF_SUBTYPES = "subtype_settings";
|
||||||
|
public static final String PREF_AUTO_CAP = "auto_cap";
|
||||||
public static final String PREF_VIBRATE_ON = "vibrate_on";
|
public static final String PREF_VIBRATE_ON = "vibrate_on";
|
||||||
public static final String PREF_SOUND_ON = "sound_on";
|
public static final String PREF_SOUND_ON = "sound_on";
|
||||||
public static final String PREF_KEY_PREVIEW_POPUP_ON = "popup_on";
|
public static final String PREF_KEY_PREVIEW_POPUP_ON = "popup_on";
|
||||||
public static final String PREF_AUTO_CAP = "auto_cap";
|
|
||||||
public static final String PREF_SHOW_SETTINGS_KEY = "show_settings_key";
|
public static final String PREF_SHOW_SETTINGS_KEY = "show_settings_key";
|
||||||
public static final String PREF_VOICE_SETTINGS_KEY = "voice_mode";
|
public static final String PREF_VOICE_SETTINGS_KEY = "voice_mode";
|
||||||
public static final String PREF_INPUT_LANGUAGE = "input_language";
|
|
||||||
public static final String PREF_SELECTED_LANGUAGES = "selected_languages";
|
|
||||||
public static final String PREF_SUBTYPES = "subtype_settings";
|
|
||||||
|
|
||||||
public static final String PREF_CONFIGURE_DICTIONARIES_KEY = "configure_dictionaries_key";
|
|
||||||
public static final String PREF_CORRECTION_SETTINGS_KEY = "correction_settings";
|
public static final String PREF_CORRECTION_SETTINGS_KEY = "correction_settings";
|
||||||
public static final String PREF_SHOW_SUGGESTIONS_SETTING = "show_suggestions_setting";
|
public static final String PREF_CONFIGURE_DICTIONARIES_KEY = "configure_dictionaries_key";
|
||||||
public static final String PREF_AUTO_CORRECTION_THRESHOLD = "auto_correction_threshold";
|
public static final String PREF_AUTO_CORRECTION_THRESHOLD = "auto_correction_threshold";
|
||||||
public static final String PREF_DEBUG_SETTINGS = "debug_settings";
|
public static final String PREF_SHOW_SUGGESTIONS_SETTING = "show_suggestions_setting";
|
||||||
|
|
||||||
public static final String PREF_BIGRAM_SUGGESTIONS = "bigram_suggestion";
|
|
||||||
public static final String PREF_BIGRAM_PREDICTIONS = "bigram_prediction";
|
|
||||||
|
|
||||||
public static final String PREF_MISC_SETTINGS_KEY = "misc_settings";
|
public static final String PREF_MISC_SETTINGS_KEY = "misc_settings";
|
||||||
|
public static final String PREF_USABILITY_STUDY_MODE = "usability_study_mode";
|
||||||
|
public static final String PREF_ADVANCED_SETTINGS = "pref_advanced_settings";
|
||||||
public static final String PREF_KEY_PREVIEW_POPUP_DISMISS_DELAY =
|
public static final String PREF_KEY_PREVIEW_POPUP_DISMISS_DELAY =
|
||||||
"pref_key_preview_popup_dismiss_delay";
|
"pref_key_preview_popup_dismiss_delay";
|
||||||
public static final String PREF_KEY_USE_CONTACTS_DICT =
|
public static final String PREF_KEY_USE_CONTACTS_DICT = "pref_key_use_contacts_dict";
|
||||||
"pref_key_use_contacts_dict";
|
public static final String PREF_BIGRAM_SUGGESTIONS = "bigram_suggestion";
|
||||||
public static final String PREF_KEY_ENABLE_SPAN_INSERT =
|
public static final String PREF_BIGRAM_PREDICTIONS = "bigram_prediction";
|
||||||
"enable_span_insert";
|
public static final String PREF_KEY_ENABLE_SPAN_INSERT = "enable_span_insert";
|
||||||
|
|
||||||
public static final String PREF_USABILITY_STUDY_MODE = "usability_study_mode";
|
|
||||||
|
|
||||||
public static final String PREF_KEYPRESS_VIBRATION_DURATION_SETTINGS =
|
public static final String PREF_KEYPRESS_VIBRATION_DURATION_SETTINGS =
|
||||||
"pref_vibration_duration_settings";
|
"pref_vibration_duration_settings";
|
||||||
|
|
||||||
public static final String PREF_KEYPRESS_SOUND_VOLUME =
|
public static final String PREF_KEYPRESS_SOUND_VOLUME =
|
||||||
"pref_keypress_sound_volume";
|
"pref_keypress_sound_volume";
|
||||||
|
|
||||||
|
public static final String PREF_INPUT_LANGUAGE = "input_language";
|
||||||
|
public static final String PREF_SELECTED_LANGUAGES = "selected_languages";
|
||||||
|
public static final String PREF_DEBUG_SETTINGS = "debug_settings";
|
||||||
|
|
||||||
// Dialog ids
|
// Dialog ids
|
||||||
private static final int VOICE_INPUT_CONFIRM_DIALOG = 0;
|
private static final int VOICE_INPUT_CONFIRM_DIALOG = 0;
|
||||||
|
|
||||||
|
|
|
@ -42,28 +42,34 @@ public class SettingsValues {
|
||||||
private final String mSymbolsExcludedFromWordSeparators;
|
private final String mSymbolsExcludedFromWordSeparators;
|
||||||
public final CharSequence mHintToSaveText;
|
public final CharSequence mHintToSaveText;
|
||||||
|
|
||||||
// From preferences:
|
// From preferences, in the same order as xml/prefs.xml:
|
||||||
public final boolean mSoundOn; // Sound setting private to Latin IME (see mSilentModeOn)
|
|
||||||
public final boolean mVibrateOn;
|
|
||||||
public final boolean mKeyPreviewPopupOn;
|
|
||||||
public final int mKeyPreviewPopupDismissDelay;
|
|
||||||
public final boolean mAutoCap;
|
public final boolean mAutoCap;
|
||||||
public final boolean mAutoCorrectEnabled;
|
public final boolean mVibrateOn;
|
||||||
public final double mAutoCorrectionThreshold;
|
public final boolean mSoundOn;
|
||||||
|
public final boolean mKeyPreviewPopupOn;
|
||||||
|
private final boolean mShowSettingsKey;
|
||||||
|
// TODO: add a member for the raw "voice_mode" setting
|
||||||
|
// TODO: add a member for the raw "auto_correction_threshold" setting
|
||||||
|
// TODO: add a member for the raw "show_suggestions_setting" setting
|
||||||
|
// TODO: add a member for the raw "usability_study_mode" setting
|
||||||
|
// TODO: add a member for the raw "pref_key_preview_popup_dismiss_delay" setting
|
||||||
|
public final boolean mUseContactsDict;
|
||||||
// Suggestion: use bigrams to adjust scores of suggestions obtained from unigram dictionary
|
// Suggestion: use bigrams to adjust scores of suggestions obtained from unigram dictionary
|
||||||
public final boolean mBigramSuggestionEnabled;
|
public final boolean mBigramSuggestionEnabled;
|
||||||
// Prediction: use bigrams to predict the next word when there is no input for it yet
|
// Prediction: use bigrams to predict the next word when there is no input for it yet
|
||||||
public final boolean mBigramPredictionEnabled;
|
public final boolean mBigramPredictionEnabled;
|
||||||
public final boolean mUseContactsDict;
|
|
||||||
public final boolean mEnableSuggestionSpanInsertion;
|
public final boolean mEnableSuggestionSpanInsertion;
|
||||||
|
// TODO: add a member for the raw "pref_vibration_duration_settings" setting
|
||||||
private final boolean mShowSettingsKey;
|
// TODO: add a member for the raw "pref_keypress_sound_volume" setting
|
||||||
private final boolean mVoiceKeyEnabled;
|
|
||||||
private final boolean mVoiceKeyOnMain;
|
|
||||||
|
|
||||||
// Deduced settings
|
// Deduced settings
|
||||||
public final int mKeypressVibrationDuration;
|
public final int mKeypressVibrationDuration;
|
||||||
public final float mFxVolume;
|
public final float mFxVolume;
|
||||||
|
public final int mKeyPreviewPopupDismissDelay;
|
||||||
|
public final boolean mAutoCorrectEnabled;
|
||||||
|
public final double mAutoCorrectionThreshold;
|
||||||
|
private final boolean mVoiceKeyEnabled;
|
||||||
|
private final boolean mVoiceKeyOnMain;
|
||||||
|
|
||||||
public SettingsValues(final SharedPreferences prefs, final Context context,
|
public SettingsValues(final SharedPreferences prefs, final Context context,
|
||||||
final String localeStr) {
|
final String localeStr) {
|
||||||
|
|
Loading…
Reference in a new issue