def __init__(self, *arg, **kw):
if 'style' in kw and (kw['style']&wx.LC_LIST or kw['style']&wx.LC_REPORT):
kw['style'] |= wx.LC_SINGLE_SEL
else:
kw['style'] = wx.LC_SINGLE_SEL|wx.LC_LIST
wx.ListCtrl.__init__(self, *arg, **kw)
self.Bind(wx.EVT_LIST_BEGIN_DRAG, self._startDrag)
dt = ListDrop(self._insert)
self.SetDropTarget(dt)
评论列表
文章目录