[wxPython] wxListCtrl and Get Info

I'm trying to get the below code to work. I need to use wxLC_USER_TEXT, but
the event doesn't seem to work. I know how to program it in MSVC++, but I'd
like to use wxPython for some quick prototyping.
Thanks.

from wxPython.wx import *
class MyFrame ( wxFrame ):
    def __init__ ( self, parent ):
        wxFrame.__init__( self, parent, 1, 'Test', size = (200, 300) )
        self.list = wxListCtrl( self, 2,
style=wxLC_REPORT|wxLC_SINGLE_SEL|wxLC_USER_TEXT )
        self.list.InsertColumn( 0, 'Hi' )
        for i in range( 10 ):
            self.list.InsertStringItem( i, 'hi' )
        EVT_LIST_GET_INFO(self.list,2,self.OnListInfo)
        self.Center()
        self.Show( true )
    def OnListInfo( self, event ):
        item = event.GetItem()
        item.m_text = 'hi'
class MyApp ( wxApp ):
    def OnInit ( self ):
        self.frame = MyFrame( None )
        self.SetTopWindow( self.frame )
        self.frame.Raise()
        return true
def run():
    app = MyApp( 0 )
    app.MainLoop()
    del app
if __name__ == "__main__":
    run()

···

_______________________________________________
wxPython-users mailing list
wxPython-users@lists.sourceforge.net
http://lists.sourceforge.net/lists/listinfo/wxpython-users