Hello,
I am still struggling with the fundamentals of event driven programming.
As long as I am working with one window/widget, everything goes
reasonably well: events happen to its buttons and text fields,
and I can use Bind() to give them a follow up.
However, my main frame + main application is a menu system,
in which the menu items start a kind of sub-things
(applications + frames), and in which the only common trait
of these subs is that they use the same database.
And what makes it really difficult for me:
many of these sub-applications start as scenario’s, use cases,
which are essentially sequential constructions, maybe altered by
some control flow.
I tried to implement each scenario in a class in which a main method
sequentially executes a number of other low-level methods.
Some of these methods do contain wxPython elements,
Other methods don’t use wxPython, beause they do their business or
database work transparently in the background.
And they don’t generate events.
Obviously this doesn’t work well in an event driven environment.
But I dont see yet how I can mix events and my sequential wishes,
or how I can convert all of it to events.
egbert
···
–
Egbert Bouwman [GMail]