Re: visualize/refactor message flow of a modular application
Christian K <[email protected]>
| Newsgroups | gmane.comp.python.wxpython |
|---|---|
| Message-ID | <[email protected]> |
Hi Steve, good idea. I will try that although it means that I have to kind of awake all events manually by using the application. Christian El viernes, 22 de mayo de 2020, 4:55:40 (UTC-3), Gadget Steve escribió: > > Christian, > > > > One ‘trick’ that I have used for addressing this sort of issue comes from > the realisation that, in python at least, events (even Windows events) can > have additional information by simply adding it to the event and of course > it doesn’t have to be used and as long as it is not excessive it has little > impact on the performance. So if within your code you add to each event > sending method something like: > > evt = wx.Event(……) # Create the event as you normally would > > evt.raised_from = (__file__, ‘a label’) # Sorry about the quotes (Outlook) > > # raise the event > > > > Then any event handler or debugging process can access and potentially > print the originator information. > > Hope that this is helpful. > > > > Steve (Gadget) Barnes > > > > *From:* [email protected] <javascript:> < > [email protected] <javascript:>> *On Behalf Of *Christian K > *Sent:* 21 May 2020 17:12 > *To:* wxPython-users <[email protected] <javascript:>> > *Subject:* [wxPython-users] visualize/refactor message flow of a modular > application > > > > In the process of over and over extending and enhancing an application > (around 50 source files) I came to the point that I cannot anymore tell > with precision where some messages came from and where they go to (both > pubsub and wx.Events). So I thought it would be nice to have a tool to > visualize the messaging structure. Do you know of such tool or do you have > recommendations for an implementation maybe even without necesity of code > inspection? > > > > Regards, Christian > > -- > You received this message because you are subscribed to the Google Groups > "wxPython-users" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected] <javascript:>. > To view this discussion on the web visit > https://groups.google.com/d/msgid/wxpython-users/a62f6e33-693a-4bbb-bdea-c69cc3cd3c4d%40googlegroups.com > <https://groups.google.com/d/msgid/wxpython-users/a62f6e33-693a-4bbb-bdea-c69cc3cd3c4d%40googlegroups.com?utm_medium=email&utm_source=footer> > . > -- You received this message because you are subscribed to the Google Groups "wxPython-users" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/wxpython-users/836f6094-6301-4f59-8172-2060a92535f6%40googlegroups.com.