#NEWLINE# def add_to_menu( self , parent , menu , controller ) : #NEWLINE# #INDENT# ' Adds the item to a menu. ' #NEWLINE# id = wx . NewId ( ) #NEWLINE# sub = self . create_menu ( parent , controller ) #NEWLINE# sub . _id = id #NEWLINE# sub . _menu = menu #NEWLINE# menu . AppendMenu ( id , sub . name , sub ) #NEWLINE# return