dsparling/jclock — pull request #4 by julienw (2011-11-22 23:04:43+00:00)
Title: Synchronized clock

with the current implementation, there is a problem when the timeout is set to 60000 (ie 1 minute) instead of the default 1000. In this case, the change (the repaint) is set to 1 minute after the startClock call, which means it will most probably not in the same time as the minute change.

This pull request tries to fix this: if the timeout is 1 minute, then we compute the timeout to be the number of seconds to the next minute.

An example file (index10.html) has been added to demonstrate this.