Update kmk/modules/encoder.py

Co-authored-by: Tonasz <27835465+Tonasz@users.noreply.github.com>
This commit is contained in:
René Giovanni BorellaandTonasz authored and Kyle Brown committed 2022-02-19 21:33:45 -08:00
1 parent 8e4ab1d733
commit 7f7eaafbf3
1 file changed
+1 -5
+1 -5
View File
@@ -87,11 +87,7 @@ class BaseEncoder:
self._timestamp = new_timestamp
def button_event(self):
new_button_state = self.pin_button.get_value()
if new_button_state != self._button_state:
self._button_state = new_button_state
if self.on_button_do is not None:
self.on_button_do(self.get_state())
raise NotImplementedError('subclasses must override button_event()!')
# return knob velocity as milliseconds between position changes (detents)
# for backwards compatibility