The notion of a debounce function is simple: limit how often function can fire by waiting a certain amount of time before executing it.
For an event that fires continuously during input, this effectively means fire the function x amount of time after input stops.
Welcome back to our Ruby Motion Tutorial for Beginners series!
In the first part of the series, you learned the basics of getting started with Ruby Motion, and created a view controller with a few styled views.
The title of changes depending on the state of the button.
It would be nice to polish your app a little further and change the background color of the button when it's selected.
Your app is really starting to take shape — but there's a little more functionality to implement.
One of the key principles of the Pomodoro Technique is that you should take a five minute break after your 25 minute block of work is over.
Expensive handlers for these actions can bog your app down and make it feel unresponsive.
You should suggest this to your user so they don't slip back into their old habits.
def alert_controller @alert_controller
Improving app performance is a key concern for all app developers, especially when it comes to the UI.