def create_tool(self, name, binding=None, style=wx.ITEM_NORMAL, s_help="", l_help=""):
l_id = id_renew(name)
IDS[l_id] = name
label_text = translate_key(IDS[l_id])
button = self.AddLabelTool(l_id, label_text, wx.NullBitmap, wx.NullBitmap,
style, s_help, l_help)
if binding:
self.main_class.Bind(wx.EVT_TOOL, binding, id=l_id)
return button
评论列表
文章目录