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

Commit b9910915 authored by Edward Savage-Jones's avatar Edward Savage-Jones Committed by Ed Savage-Jones
Browse files

Use a fallback vibration effect for GESTURE_END

In the case where there is no hardware tuned effect, fallback to
the generic implementation for EFFECT_TICK.

Bug: 185418411
Test: manual
Change-Id: I3c00d1db363bb11f8d18faa762589b1937c4370c
parent 964fccfe
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -5257,6 +5257,7 @@ public class PhoneWindowManager implements WindowManagerPolicy {
        long[] pattern;
        switch (effectId) {
            case HapticFeedbackConstants.CONTEXT_CLICK:
            case HapticFeedbackConstants.GESTURE_END:
                return VibrationEffect.get(VibrationEffect.EFFECT_TICK);
            case HapticFeedbackConstants.TEXT_HANDLE_MOVE:
                if (!mHapticTextHandleEnabled) {
@@ -5269,7 +5270,6 @@ public class PhoneWindowManager implements WindowManagerPolicy {
            case HapticFeedbackConstants.VIRTUAL_KEY_RELEASE:
            case HapticFeedbackConstants.ENTRY_BUMP:
            case HapticFeedbackConstants.DRAG_CROSSING:
            case HapticFeedbackConstants.GESTURE_END:
                return VibrationEffect.get(VibrationEffect.EFFECT_TICK, false);
            case HapticFeedbackConstants.KEYBOARD_TAP: // == KEYBOARD_PRESS
            case HapticFeedbackConstants.VIRTUAL_KEY: