summaryrefslogtreecommitdiff
path: root/lyricstimer/timelyrics
diff options
context:
space:
mode:
authorTim Redfern <tim@eclectronics.org>2013-11-18 15:29:40 +0000
committerTim Redfern <tim@eclectronics.org>2013-11-18 15:29:40 +0000
commitb46286b8262cd5a4b96ac318a6d85d3db39e09e5 (patch)
tree61e6e2de8d22193f3f066100648de30dc28fa349 /lyricstimer/timelyrics
parenta36735b4585521218268da5fed2214ba239b4c2a (diff)
lyrics rough version
Diffstat (limited to 'lyricstimer/timelyrics')
-rwxr-xr-xlyricstimer/timelyrics8
1 files changed, 4 insertions, 4 deletions
diff --git a/lyricstimer/timelyrics b/lyricstimer/timelyrics
index 2d6e071..7b50d0e 100755
--- a/lyricstimer/timelyrics
+++ b/lyricstimer/timelyrics
@@ -34,15 +34,15 @@ enable_echo( sys.stdin.fileno(),False)
start=0.0
down=0.0
+printeddown=0.0
state="up"
-count=0
def handle_up (event):
- global start,down,state,count
- if count>0:
+ global start,down,state,printeddown
+ if printeddown!=down:
print "[",down,",",time()-(start+down),"]"
+ printeddown=down
state="up"
- count+=1
def handle_down (event):
global start,down,state