do the haptic feedback onPress, not onKey

This commit is contained in:
tibbi 2022-01-11 23:52:41 +01:00
parent 91b3557c2d
commit 3714a61ad7

View file

@ -23,7 +23,9 @@ class SimpleKeyboardIME : InputMethodService(), MyKeyboardView.OnKeyboardActionL
return keyboardView!!
}
override fun onPress(primaryCode: Int) {}
override fun onPress(primaryCode: Int) {
keyboardView?.performHapticFeedback()
}
override fun onRelease(primaryCode: Int) {}
@ -56,7 +58,6 @@ class SimpleKeyboardIME : InputMethodService(), MyKeyboardView.OnKeyboardActionL
}
}
}
keyboardView?.performHapticFeedback()
}
override fun onText(text: CharSequence?) {}