コード例 #1
0
 def __init__(self, str1=None, str2=None, int1=None, int2=None):
     gtk.HBox.__init__(self, False, 0)
     self.entry = DateEntryField(str1, str2, int1, int2)
     self.button = gtk.ToggleButton()
     self.button.set_property("can-focus", False)
     #image = gtk.Image()
     image = gtk.image_new_from_stock(gtk.STOCK_FIND, gtk.ICON_SIZE_MENU)
     #pbuf = gtk.gdk.pixbuf_new_from_file(Environment.conf.guiDir + 'calendario16x16.png')
     #image.set_from_pixbuf(pbuf)
     self.button.add(image)
     self.pack_start(self.entry, True, True, 0)
     self.pack_start(self.button, False, False, 0)
     self.button.connect('clicked', self.do_button_clicked)
     self.connect("show", self.on_show)
     self.entry.connect('focus_out_event', self.do_focus_out_event)