diff options
author | Sean Whitton <spw+git@sdf.org> | 2014-11-12 14:48:02 +0900 |
---|---|---|
committer | Sean Whitton <spw+git@sdf.org> | 2014-11-12 14:48:02 +0900 |
commit | 29a618e315bc3a60cde3caeee76d851b2fd5d261 (patch) | |
tree | da4e333e6b687c05bb1c590f61e772105a8ba77b | |
parent | 33ceed50e3f44368d989ae9aabac9033a40f9c51 (diff) | |
download | schoolclock-29a618e315bc3a60cde3caeee76d851b2fd5d261.tar.gz |
improve hotkey choice
-rw-r--r-- | index.html | 10 | ||||
-rw-r--r-- | js/main.js | 6 |
2 files changed, 9 insertions, 7 deletions
@@ -53,9 +53,9 @@ <br /> <a id="timeWastingClockGo" class="btn btn-primary btn-lg - btn-block">Start timer (Hotkey: j)</a> + btn-block">Start <u>t</u>imer</a> <a id="timeWastingClockReset" class="btn btn-default btn-lg - btn-block">Reset timer (end of class)</a> + btn-block">Re<u>s</u>et timer (end of class)</a> </div> <div class="col-md-6"> <h1>Activity time</h1><br /> @@ -74,12 +74,12 @@ </p> <p class="text-center"> - <a id="activityClockCustom" class="btn btn-default btn-lg">Custom</a> - <a id="activityClockReset" class="btn btn-default btn-lg">Reset</a> + <a id="activityClockCustom" class="btn btn-default btn-lg"><u>C</u>ustom</a> + <a id="activityClockReset" class="btn btn-default btn-lg"><u>R</u>eset</a> </p> <p class="text-center"> - Hotkey: press the number key for the number of minutes you want + Hotkeys: press the number key for the number of minutes you want to countdown. </p> </div> @@ -51,19 +51,21 @@ function timeWastingClockToggle() { if ($timeWastingClockRunning) { - $('#timeWastingClockGo').html('Start timer (Hotkey: j)'); + $('#timeWastingClockGo').html('Start <u>t</u>imer'); timeWastingClock.stop(); $timeWastingClockRunning = false; } else { - $('#timeWastingClockGo').html('Stop timer (Hotkey: j)'); + $('#timeWastingClockGo').html('Stop <u>t</u>imer'); timeWastingClock.start(); $timeWastingClockRunning = true; } } +$(document).bind('keydown', 't', timeWastingClockToggle); $(document).bind('keydown', 'j', timeWastingClockToggle); + $(document).bind('keydown', 'k', function (){$.ionSound.play("klaxon");}); function activityClockGo($seconds) |