mozilla-b2g/gaia — pull request #12131 by rwaldron (2013-09-11 17:59:55+00:00)
Title: Bug 912250 - [Clock] Implement Timer view

https://bugzilla.mozilla.org/show_bug.cgi?id=912250

- Timer object
- Create or revive a new or existing Timer object
- tick method executes every second, emit "tick" event while state is Timer.STARTED
- start method updates startAt, sets Timer.STARTED state, initiates tick()
- pause method sets Timer.PAUSED
- cancel method sets Timer.CANCELED, purges timer from storage
- notify method handles user notification.
- Timer.View object
- Initialize a single UI view
- Interact with the currently active Timer object
- Update view on Timer object tick events

- Utils
- moves formatTime to Utils.format.time
- creates new Utils.format.hms
- Updates and adds tests.

Signed-off-by: Rick Waldron