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

Commit 6a800b25 authored by Jean Chalard's avatar Jean Chalard
Browse files

Some more simplification

Remove useless method calls, and ultimately remove useless
method.

Change-Id: I3f353b1b37460d5e9ceae5cb5dde3fff0da81c21
parent 7ef97ea1
Loading
Loading
Loading
Loading
+2 −4
Original line number Diff line number Diff line
@@ -2107,13 +2107,11 @@ public class LatinIME extends InputMethodServiceCompatWrapper implements Keyboar
        CharSequence toLeft = ic.getTextBeforeCursor(1, 0);
        CharSequence toRight = ic.getTextAfterCursor(1, 0);
        if (!TextUtils.isEmpty(toLeft)
                && !mSettingsValues.isWordSeparator(toLeft.charAt(0))
                && !mSettingsValues.isSuggestedPunctuation(toLeft.charAt(0))) {
                && !mSettingsValues.isWordSeparator(toLeft.charAt(0))) {
            return true;
        }
        if (!TextUtils.isEmpty(toRight)
                && !mSettingsValues.isWordSeparator(toRight.charAt(0))
                && !mSettingsValues.isSuggestedPunctuation(toRight.charAt(0))) {
                && !mSettingsValues.isWordSeparator(toRight.charAt(0))) {
            return true;
        }
        return false;
+0 −4
Original line number Diff line number Diff line
@@ -222,10 +222,6 @@ public class SettingsValues {
                res.getBoolean(R.bool.config_default_vibration_enabled));
    }

    public boolean isSuggestedPunctuation(int code) {
        return mSuggestPuncs.contains(String.valueOf((char)code));
    }

    public boolean isWordSeparator(int code) {
        return mWordSeparators.contains(String.valueOf((char)code));
    }