-
Notifications
You must be signed in to change notification settings - Fork 10
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: enabling continuous button press #7
base: master
Are you sure you want to change the base?
Feature: enabling continuous button press #7
Conversation
…nputValue is updated inside the callback)
…thout ngTouch plugin
further commits to make usable both on PC browsers and touchscreen devices. Introduced
Also, introduced a 600ms delay before autorepeat for better usability. |
Is this going to get merged to master? |
@mikepc For the time being, use my forked master instead. Will get this pull request without a conflict later. |
…uous-button-press
Just needs to be cleaned up and I can merge. |
Hi, this patch includes one bugfix (when returning negative value), and also a huge feature addition.
This enables "autorepeat" feature: numbers continuously up/down while pressing increment/decrement buttons. So you don't have to click/tap up/down buttons number of times anymore, in order to increase/decrease numbers plenty. To accomplish this, I changed the way negative sign and current value(s) are displayed (from
ng-bind
to direct DOM manipulation).Also, since touchscreen devices (such as smartphones and tablets) cannot handle
mousedown
andmouseup
events, I addedng-touchstart
andng-touchend
directives. If you add ngTouch ( https://github.com/nglar/ngTouch ) module, autorepeat feature will be enabled on touchscreen devices as well. Without ngTouch module, these directives are simply ignored.Hope you'll like this.