On 5/7/10 2:42 PM, John wrote:
> What is the correct way to create a custom event for a form?  I would like to
> use the Framework and not wx.lib.newevent (IOW not drop down to wx).  I have
> a custom control that will need a custom event to be raised.

Subclass your event from dabo.dEvents.Event (or an appropriate subclass of 
that, e.g. 
GridEvent, TreeEvent, MouseEvent, etc.)

Define your evt._appliesToClass function (see dEvent.py for plenty of examples).

Then when you want to raise the event, call self.raiseEvent(MyEvent, <optional 
args 
and kwargs to pass to the handler>)

Paul
_______________________________________________
Post Messages to: [email protected]
Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: http://leafe.com/archives/byMID/[email protected]

Reply via email to