Web · Wiki · Activities · Blog · Lists · Chat · Meeting · Bugs · Git · Translate · Archive · People · Donate

Commit 531ee414eca9ab020439b111b6b6aed929ec12c5

remove some dead code
scan.py
(0 / 54)
  
4545from sugar.logger import trace
4646
4747
48class ToolEntry(gtk.ToolItem):
49
50 def __init__(self, **kwargs):
51 gtk.ToolItem.__init__(self)
52 self.entry = gtk.Entry(**kwargs)
53 self.entry.show()
54 self.add(self.entry)
55
56 def modify_bg(self, state, color):
57 gtk.ToolItem.modify_bg(self, state, color)
58 self.entry.modify_bg(state, color)
59
60 def get_text(self):
61 return self.entry.get_text()
62
63 def set_text(self, text):
64 self.entry.set_text(text)
65
66 def connect(self, *args):
67 self.entry.connect(*args)
68
69 def set_sensitive(self, sensitive):
70 self.entry.set_sensitive(sensitive)
71
72
73class ToolCheckButton(gtk.ToolItem):
74
75 def __init__(self, **kwargs):
76 gtk.ToolItem.__init__(self)
77 self.button = gtk.CheckButton(**kwargs)
78 self.button.show()
79 self.add(self.button)
80
81 def modify_bg(self, state, color):
82 gtk.ToolItem.modify_bg(self, state, color)
83 self.button.modify_bg(state, color)
84
85 def get_active(self):
86 return self.button.get_active()
87
88 def set_active(self, active):
89 self.button.set_active(active)
90
91 def connect(self, *args):
92 self.button.connect(*args)
93
94 def set_sensitive(self, sensitive):
95 self.button.set_sensitive(sensitive)
96
97
9848class SettingsToolbar(gtk.Toolbar):
9949
10050 @trace()
532532 return
533533
534534 self._settings_toolbar.set_scanner(self._scanners[0])
535
536# logging.debug('setting scanner options: %r', self._scanner_options)
537# for name, value in self._scanner_options.items():
538# setattr(self._scanners[0], name, value)
539535
540536 self._set_status('ready')
541537