You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Fix bug where isPressed returns True a second time
As currently implemented, if the button is pressed and immediately released
before the next `loop` call, e.g., due to a blocking action like a `delay`
call, the subsequent `loop` call will still consider the button as pressed. The
same behavior occurs with unpressed when holding the button, and only
momentarily releasing it.
To fix this issue, we need to do away with the `previousSteadyState` variable
so that it does not require two calls to `loop` in order to change the state.
0 commit comments