Fix missing ticks resulting from early wakeups

The main loop sleeps up to the next second, but the decision
to redraw according to the changed time should use the rounded
version of gettimeofday(), and we should only call it once.