def set_icon_theme(self, name):
     try:
         pixbuf = self.load_icon(name)
         if pixbuf:
             self.set_pixbuf(pixbuf)
     except Exception, e:
         print_msg("set_icon_theme[error]:%s"%(e))
 def start(self):
     self.send_event_to_dock(
                     self.tray_win,
                     self.opcode_atom,
                     [X.CurrentTime, 0L, self.tray_widget_wind.id, 0L, 0L],
                     X.NoEventMask)
     self.xdisplay.flush()
     print_msg("start......")
 def __widget_clicked_event(self, widget):
     # emit event.
     self.emit("popup-menu-event", self.get_geometry())
     try:
         if self.popup_menu:
             self.popup_menu(widget, self.get_geometry())
     except Exception, e:
         print_msg("widget_clicked_event[error]:%s"%(e))
 def remove_plugin(self, widget):
     if self.main_ali.get_children() != []:
         self.main_ali.remove(widget)
     else:
         print_msg("main_ali no widgets")