From 5265525b2b6341987f3fe6bc368f5f58ce953879 Mon Sep 17 00:00:00 2001 From: Mark Tearle <mark@tearle.com> Date: Sat, 14 Mar 2015 21:19:06 +0800 Subject: [PATCH] Remove redundant code --- virtualcoke.py | 34 ---------------------------------- 1 file changed, 34 deletions(-) diff --git a/virtualcoke.py b/virtualcoke.py index bbd49c3..e3a9643 100755 --- a/virtualcoke.py +++ b/virtualcoke.py @@ -153,40 +153,6 @@ class VirtualCoke(npyscreen.Form): self.slots.append(widget) - - # FIXME Hook up widgets and callbacks - # - - -# self.textdisplay = self.add(npyscreen.FixedText, value=self.parentApp.textdisplay, editable=False, relx=9) -# self.textdisplay.important = True - -# self.kpbuttons = [] -# kpx = 1 -# kpy = 1 -# for keypad in range(0,10): -# kpx = ((keypad % 4) * 6 ) + 3 -# kpy = int(keypad / 4) + 4 -# widget = self.add(CokeButtonPress,name="%d"%keypad, relx = kpx, rely = kpy, when_pressed_callback=self.parentApp.when_keypad_pressed) -# self.kpbuttons.append(widget) -# self.add_handlers({"%d"%keypad: widget.whenPressed}) - -# self.reset=self.add(CokeButtonPress,name="RESET", relx = kpx + 7, rely = kpy, when_pressed_callback=self.parentApp.when_reset_pressed) -# self.add_handlers({"R": self.reset.whenPressed}) -# self.add_handlers({"r": self.reset.whenPressed}) - -# self.dip = self.add(npyscreen.MultiSelect, name = "Door", max_width=15, relx = 4, rely = 12, max_height=4, value = [], values = ["DOOR"], scroll_exit=True, value_changed_callback=self.parentApp.when_door_toggled) - -# self.dip = self.add(npyscreen.MultiSelect, name = "DIP Switch", max_width=10, rely =3, relx = 35, max_height=10, value = [], values = ["DIP1", "DIP2", "DIP3","DIP4","DIP5","DIP6","DIP7","DIP8"], scroll_exit=True) - -# self.nickel=self.add(CokeButtonPress,name="0.05", rely= 3, relx=50) -# self.dime=self.add(CokeButtonPress,name="0.10", relx=50) -# self.quarter=self.add(CokeButtonPress,name="0.25", relx=50) -# self.dollar=self.add(CokeButtonPress,name="1.00", relx=50) - -# self.mode=self.add(CokeButtonPress,name="MODE", relx=50) - - self.date_widget = self.add(npyscreen.FixedText, value=datetime.now().ctime(), editable=False, rely=19) self.date_widget.value = "Hello" self.add_handlers({"^Q": self.exit_application}) -- GitLab