Changeset 140
- Timestamp:
- 04/14/08 16:32:09 (6 months ago)
- Files:
-
- sucrose/trunk/python/keypad_tk.py (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
sucrose/trunk/python/keypad_tk.py
r139 r140 37 37 38 38 self.window = Tkinter.Tk() 39 cursor_file = os.path.join(os.path.dirname(__file__), 'emptycursor.xbm') 40 self.window.config(cursor='@%s white' % cursor_file) 39 if __name__ != '__main__': 40 cursor_file = os.path.join(os.path.dirname(__file__), 41 'emptycursor.xbm') 42 self.window.config(cursor='@%s white' % cursor_file) 41 43 self.window.title('Sucrose') 42 44 self.window.geometry('800x600+0+0') … … 82 84 self.view_buttons[view].config(relief=Tkinter.SUNKEN) 83 85 view.grid(row=1, column=0) 84 self.reset_idle_timeout() 86 if __name__ != '__main__': 87 self.reset_idle_timeout() 85 88 86 89 … … 90 93 for i in self.view_names: 91 94 getattr(self,i).destroy() 95 if hasattr(self, 'timeout_id'): 96 self.window.after_cancel(self.timeout_id) 92 97 self.window.destroy() 93 98 del self.window
