[Tutor] how to post an event?

Alan Gauld alan.gauld at freenet.co.uk
Fri Jul 7 22:59:32 CEST 2006


> Hello, I am having a bit of trouble figuring out how to post an 
> event.

Do you really need to post an event?

>        self.button2.Bind(wx.EVT_BUTTON, self.OnButton2Button,
>              id=wxID_FRAME1BUTTON2)

could you just bi8nd the same method to both buttons?

>    def OnButton1Button(self, event):
>        print 'hello'
>
>    def OnButton2Button(self, event):
>        event.Skip()
>        """what do I do here to post an event that executes 
> 'OnButton1Button()' ?"""

Or could you call OnButton1Button(self,event) directly?

Does it have to involve an event being posted to the Q - sometimes
needed I know but not often...

Alan G.

> 




More information about the Tutor mailing list