Lars Uffmann
2008-03-18 12:07:25 UTC
Hi everyone,
I'm using wxFormBuilder - starting to get the hang of it - but now I
haven't modified my form for a while, and have introduced an event
handler of my own to the application (for use with threading and
wxPostEvent), that is not linked to any of the "Events" of the widgets /
controls. So I added the virtual event handler to the GUI-part of the
code (the wxFormBuilder-generated files), including connecting it to the
main frame in the constructor, and disconnecting in the destructor.
Upon my next use of wxFormBuilder, I'm bound to run into manual editing
there - so I was wondring what the better approach to adding custom
event handlers would be.
Skip the virtual event handler, and only add it to the derived class
that holds the real event handlers? Then include the connect and
disconnect in that class' constructor / destructor? Or what would you
suggest?
Any ideas welcome :)
Lars
I'm using wxFormBuilder - starting to get the hang of it - but now I
haven't modified my form for a while, and have introduced an event
handler of my own to the application (for use with threading and
wxPostEvent), that is not linked to any of the "Events" of the widgets /
controls. So I added the virtual event handler to the GUI-part of the
code (the wxFormBuilder-generated files), including connecting it to the
main frame in the constructor, and disconnecting in the destructor.
Upon my next use of wxFormBuilder, I'm bound to run into manual editing
there - so I was wondring what the better approach to adding custom
event handlers would be.
Skip the virtual event handler, and only add it to the derived class
that holds the real event handlers? Then include the connect and
disconnect in that class' constructor / destructor? Or what would you
suggest?
Any ideas welcome :)
Lars