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

Commit 37af28dd authored by Ken Wakasa's avatar Ken Wakasa
Browse files

Enable vibrate on keypress by default

bug: 5337363
Change-Id: I14c95d27dd236d0a43e64a46ae6fbf9f2a97a3da
parent 34a98318
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -39,6 +39,7 @@
    <bool name="config_default_bigram_prediction">false</bool>
    <bool name="config_default_compat_recorrection_enabled">true</bool>
    <bool name="config_default_sound_enabled">false</bool>
    <bool name="config_default_vibration_enabled">true</bool>
    <bool name="config_auto_correction_spacebar_led_enabled">true</bool>
    <!-- Showing mini keyboard, just above the touched point if true, aligned to the key if false -->
    <bool name="config_show_mini_keyboard_at_touched_point">false</bool>
+1 −1
Original line number Diff line number Diff line
@@ -20,7 +20,7 @@
<resources>
    <string-array name="keypress_vibration_durations" translatable="false">
        <!-- Build.HARDWARE,duration_in_milliseconds -->
        <item>herring,4</item>
        <item>herring,5</item>
        <item>tuna,5</item>
    </string-array>
</resources>
+1 −0
Original line number Diff line number Diff line
@@ -32,6 +32,7 @@
        <CheckBoxPreference
            android:key="vibrate_on"
            android:title="@string/vibrate_on_keypress"
            android:defaultValue="@bool/config_default_vibration_enabled"
            android:persistent="true" />
        <CheckBoxPreference
            android:key="sound_on"
+2 −1
Original line number Diff line number Diff line
@@ -171,7 +171,8 @@ public class Settings extends InputMethodSettingsActivity

            // Get the settings preferences
            final boolean hasVibrator = VibratorCompatWrapper.getInstance(context).hasVibrator();
            mVibrateOn = hasVibrator && prefs.getBoolean(Settings.PREF_VIBRATE_ON, false);
            mVibrateOn = hasVibrator && prefs.getBoolean(Settings.PREF_VIBRATE_ON,
                    res.getBoolean(R.bool.config_default_vibration_enabled));
            mSoundOn = prefs.getBoolean(Settings.PREF_SOUND_ON,
                    res.getBoolean(R.bool.config_default_sound_enabled));
            mKeyPreviewPopupOn = isKeyPreviewPopupEnabled(prefs, res);