changeset 368:ce302e4a73dc

keyboardcomposer: hw startup should move if value is 0
author David McClosky <dmcc@bigasterisk.com>
date Fri, 15 Jun 2007 17:47:45 +0000
parents 0db89c347000
children f5786ee17219
files bin/keyboardcomposer
diffstat 1 files changed, 3 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/bin/keyboardcomposer	Fri Jun 15 17:41:32 2007 +0000
+++ b/bin/keyboardcomposer	Fri Jun 15 17:47:45 2007 +0000
@@ -240,8 +240,9 @@
         
         # workaround for some rounding issue, where we receive one
         # value and then decide to send back a value that's one step
-        # lower
-        if abs(v - self.sliders.lastValue.get(chan, 0)) <= 1:
+        # lower.  -5 is a fallback for having no last value.  hopefully
+        # we won't really see it
+        if abs(v - self.sliders.lastValue.get(chan, -5)) <= 1:
             return
         self.sliders.valueOut(chan, v)