Continuously increase integer value as the button is pressed
For that to work, you need a thread that will update the integer value when you long press on a button. Create a handler in your activity: private Handler repeatUpdateHandler = new Handler(); And 2 vars which will state: is it increment or decrement? Only one set at a time. private boolean mAutoIncrement = false; … Read more