Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature request: Reset pressed time. #67

Open
JotarOne opened this issue Apr 19, 2022 · 0 comments
Open

Feature request: Reset pressed time. #67

JotarOne opened this issue Apr 19, 2022 · 0 comments

Comments

@JotarOne
Copy link

I have a case where I am using two buttons.
I am using "pressedFor" to trigger long press and if i press both buttons I can get an "extra" long press function.
My issue is that when i release one of the buttons, the other one triggers my "single button long press".
A function to reset the pressed time of the "other" button would force the "other" button to wait the whole allotted time again before pressedFor returns true.

Example:

void EasyButtonBase::resetTime()
{
	_last_change = millis();
} 

Thanks for a good, usable library!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant