Mercurial > code > home > repos > light9
diff bin/curvecalc @ 751:5656767ca025
first drop action of a sub successfully gets current music time
Ignore-this: 1e0b9a46c771e5e51c182c2a45e259cc
author | drewp@bigasterisk.com |
---|---|
date | Fri, 15 Jun 2012 20:49:57 +0000 |
parents | 62f99e2a00ac |
children | 20d6884478bc |
line wrap: on
line diff
--- a/bin/curvecalc Fri Jun 15 20:49:52 2012 +0000 +++ b/bin/curvecalc Fri Jun 15 20:49:57 2012 +0000 @@ -48,6 +48,7 @@ def __init__(self, graph, opts, song, curveset, subterms, music): self.graph, self.opts, self.song = graph, opts, song self.curveset, self.subterms, self.music = curveset, subterms, music + self.lastSeenInputTime = 0 wtree = self.wtree = gtk.Builder() wtree.add_from_file("light9/curvecalc/curvecalc.glade") @@ -96,7 +97,7 @@ except SubtermExists: pass curveView = self.curvesetView.row(subName).curveView - t = curveView.current_time() + t = self.lastSeenInputTime # curveView.current_time() # new curve hasn't heard the time yet print "time", t curveView.add_point((t - .5, 0)) curveView.add_point((t, 1)) @@ -218,6 +219,8 @@ dispatcher.connect(lambda val, value=value, tf=textfilter: value.set_text(tf(val)), signame, weak=False) + dispatcher.connect(lambda val: setattr(self, 'lastSeenInputTime', val), + 'input time', weak=False) master.show_all() def refreshCurveView(self):