changeset 385:e6f5ffb6a1b4

keyboardcomposer: zero hw sliders not used by row
author David McClosky <dmcc@bigasterisk.com>
date Fri, 15 Jun 2007 22:08:09 +0000
parents d596d932a7f1
children 551f06733559
files bin/keyboardcomposer
diffstat 1 files changed, 5 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/bin/keyboardcomposer	Fri Jun 15 22:01:09 2007 +0000
+++ b/bin/keyboardcomposer	Fri Jun 15 22:08:09 2007 +0000
@@ -180,13 +180,15 @@
         for col in range(8):
             try:
                 subtk = self.slider_table[(self.current_row, col)]
-                self.sliders.valueOut("button-upper%d" % (col + 1), 127)
+                col += 1
+                self.sliders.valueOut("button-upper%d" % col, 127)
             except KeyError:
                 # unfilled bottom row has holes (plus rows with incomplete
                 # groups
-                self.sliders.valueOut("button-upper%d" % (col + 1), 0)
+                self.sliders.valueOut("button-upper%d" % col, 0)
+                self.sliders.valueOut("slider%d" % col, 0)
                 continue
-            self.send_to_hw(subtk.name, col + 1)
+            self.send_to_hw(subtk.name, col)
             
     def got_nudger(self, number, direction, full=0):
         subtk = self.slider_table[(self.current_row, number)]