On 05/07/2010 15:57, Svend Haugaard S?rensen wrote:> I have some problem making a custom event.
>
> It seem like the initilizer is not visible
> in the scope. Why is that?
>
For some reason the allocator (constructor) function for Wx::Event is
undefined - I''ve just checked the sources and I don''t know why
SWIG is
doing that. It may be a regression.
Can you inherit from Wx::CommandEvent or some other Event class instead.
You are calling super with the parameters for Wx::CE anyway. That works
fine for me (as per the sample).
PS - at line 21 you call Wx::EvtHandler.process_event. #process_event is
an instance method, not a class method. Every Window, plus the App, has
an event_handler (with an accessor). You pass the event to one of those,
normally the one where the event originates so that it can bubble upwards.
hth
alex