Let's say, we have a simple digital clock. To "power" it, we use a routine executed every second. We update seconds part in it. But, what about minutes and hours part?
What is better / more professional / offers better performance:
Ignore all checking and update hour, minute and seconds part each time, every second.
if+ a variable for checking, if 60 (or 3600) seconds passed and update minute / hour part only at that precise moments.
This leads us to a question, what is better -- unnecessary drawings (first approach) or extra
I'm not to experienced developer, so I might me wrong. But everything, what I've learnt up until now, tells me, that
if are far better then executing drawing / refreshing sequences only to draw the same content.