Skip to content

Commit

Permalink
修正计时器
Browse files Browse the repository at this point in the history
  • Loading branch information
jmxhyz committed Aug 18, 2015
1 parent 7752215 commit 041756e
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion assets/js/nodeppt.control.socket.js
Original file line number Diff line number Diff line change
Expand Up @@ -166,13 +166,14 @@ Slide.Control.add('socket', function(S, broadcast) {
var hour = 0,
sec = 0,
min = 0;
timer = setInterval(function() {
timer2 = setInterval(function() {
sec++;
if (sec === 60) {
sec = 0;
min++;
}
if (min === 60) {
min = 0;
hour++;
}
$timer.innerHTML = ['时间:' + time2str(hour), time2str(min), time2str(sec) + ' 幻灯片:' + Slide.current + '/' + Slide.count].join(':');
Expand Down

0 comments on commit 041756e

Please sign in to comment.