kSystemSoundID_Vibrate when haptics not available#131
kSystemSoundID_Vibrate when haptics not available#131zywek123 wants to merge 2 commits intobenjamindean:masterfrom
Conversation
…reen is locked or app minimized
| return | ||
| } | ||
|
|
||
| guard let pattern = myArgs["pattern"] as? [Int] else { |
There was a problem hiding this comment.
In this case the device will vibrate once if the pattern argument is not provided. For example, if you only provide duration.
|
@benjamindean and what's wrong with that? What is the default behavior? |
Users should be able to vibrate with only duration. And duration can be of any value. |
|
OK, will revert it. |
Haptics not work when screen is locked, as mentioned in #94 which is not merged.
So, play kSystemSoundID_Vibrate, when haptic engine not works.