Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 5455179b authored by Dan Zivkovic's avatar Dan Zivkovic
Browse files

Revert "Next-word suggestion bit in keyboard settings."

This reverts commit 1ae16dc3.

Bug 19596067.

Change-Id: Ie7286acbb70b215d7bd08e271bcf14526b68576f
parent 180a1e36
Loading
Loading
Loading
Loading
+3 −0
Original line number Diff line number Diff line
@@ -20,6 +20,9 @@

<resources>
    <bool name="config_block_potentially_offensive">true</bool>
    <!-- Default value for next word prediction: after entering a word and a space only, should we
         look at input history to suggest a hopefully helpful suggestions for the next word? -->
    <bool name="config_default_next_word_prediction">true</bool>

    <integer name="config_delay_in_milliseconds_to_update_shift_state">100</integer>
    <integer name="config_double_space_period_timeout">1100</integer>
+5 −0
Original line number Diff line number Diff line
@@ -157,6 +157,11 @@
    <!-- Option to suggest auto correction suggestions very aggressively. Auto-corrects to a word which has even large edit distance from typed word. [CHAR LIMIT=20] -->
    <string name="auto_correction_threshold_mode_very_aggressive">Very aggressive</string>

    <!-- Option to enable using next word suggestions. After the user types a space, with this option on, the keyboard will try to predict the next word. -->
    <string name="bigram_prediction">Next-word suggestions</string>
    <!-- Description for "next word suggestion" option. This displays suggestions even when there is no input, based on the previous word. -->
    <string name="bigram_prediction_summary">Use the previous word in making suggestions</string>

    <!-- Option to enable gesture input. The user can input a word by tracing the letters of a word without releasing the finger from the screen. [CHAR LIMIT=30]-->
    <string name="gesture_input">Enable gesture typing</string>
    <!-- Description for "gesture_input" option. The user can input a word by tracing the letters of a word without releasing the finger from the screen. [CHAR LIMIT=65]-->
+6 −0
Original line number Diff line number Diff line
@@ -65,4 +65,10 @@
        android:summary="@string/use_contacts_dict_summary"
        android:defaultValue="true"
        android:persistent="true" />
    <CheckBoxPreference
        android:key="next_word_prediction"
        android:title="@string/bigram_prediction"
        android:summary="@string/bigram_prediction_summary"
        android:defaultValue="true"
        android:persistent="true" />
</PreferenceScreen>
+5 −1
Original line number Diff line number Diff line
@@ -1530,7 +1530,11 @@ public class LatinIME extends InputMethodService implements KeyboardActionListen
    // punctuation suggestions (if it's disabled).
    @Override
    public void setNeutralSuggestionStrip() {
        setSuggestedWords(SuggestedWords.getEmptyInstance());
        final SettingsValues currentSettings = mSettings.getCurrent();
        final SuggestedWords neutralSuggestions = currentSettings.mBigramPredictionEnabled
                ? SuggestedWords.getEmptyInstance()
                : currentSettings.mSpacingAndPunctuations.mSuggestPuncList;
        setSuggestedWords(neutralSuggestions);
    }

    // TODO: Make this private
+5 −0
Original line number Diff line number Diff line
@@ -1395,6 +1395,11 @@ public final class InputLogic {
            return;
        }

        if (!mWordComposer.isComposingWord() && !settingsValues.mBigramPredictionEnabled) {
            mSuggestionStripViewAccessor.setNeutralSuggestionStrip();
            return;
        }

        final AsyncResultHolder<SuggestedWords> holder = new AsyncResultHolder<>();
        mInputLogicHandler.getSuggestedWords(inputStyle, SuggestedWords.NOT_A_SEQUENCE_NUMBER,
                new OnGetSuggestedWordsCallback() {
Loading