about summary refs log tree commit diff
path: root/patches/expo-haptics+14.1.4.patch
blob: 9c7b9a666341375906afd30216d7c3676cfba2eb (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
diff --git a/node_modules/expo-haptics/android/src/main/java/expo/modules/haptics/HapticsModule.kt b/node_modules/expo-haptics/android/src/main/java/expo/modules/haptics/HapticsModule.kt
index 1520465..6ea988a 100644
--- a/node_modules/expo-haptics/android/src/main/java/expo/modules/haptics/HapticsModule.kt
+++ b/node_modules/expo-haptics/android/src/main/java/expo/modules/haptics/HapticsModule.kt
@@ -42,7 +42,7 @@ class HapticsModule : Module() {
 
   private fun vibrate(type: HapticsVibrationType) {
     if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.O) {
-      vibrator.vibrate(VibrationEffect.createWaveform(type.timings, type.amplitudes, -1))
+      vibrator.vibrate(VibrationEffect.createWaveform(type.oldSDKPattern, intArrayOf(0, 100), -1))
     } else {
       @Suppress("DEPRECATION")
       vibrator.vibrate(type.oldSDKPattern, -1)