Need help about 'good practice' and give event in bind widget

I’ve just uploaded an example of how one could separate the event handling from the control: it’s all there in wx!!! :smiling_face_with_three_hearts:

On the exemple i dont see how do you separate them. It’s not separate in the file its in different file that im speaking

Oh my dear, good that you told me (I bet you are a real rascal) and try to have the two files near each other when you test it: for simplicity the one with a ‘1’ in its name is the main etc (but maybe you have covered these elementaries already and I simply worry too much, happens lately)

give it a try and if … don’t hesitate etc :sweat:

gamer_button_cls_evthdlr_flash1.py (1.1 KB)
gamer_button_cls_evthdlr_flash2.py (1.6 KB)

Didnt get the part with ‘rascal’ was i rude in the last post? Didnt mean to if it was . Im going to check it tommorow after class ty.

I just have to gave them wx.EvtHandler to get the event from other file ? Oo

I’m a European and therefore not native English speaker, but rascal for me is not rude. Once upon a time my then English Lady friend had cats (usually one at a time) and when they swung in the curtains and I tried to tell them off the good old German way she would just say: oh well they are little rascals! Maybe I got it wrong but it’s one one those heavy context driven terms I rather like because they are the molesters letting AI go to the walls!
I believe that brains (human or animal) are not just a pile up of bits & pieces and if the disc is big enough the two valued logic will do it: it’s just another disguise of creator. Those ideas are just driven by the anxiety we may not master it, the negative part of zealous ambition at times when the aim gets foggy, and those who are vigorous enough make a business model out of it (but I think I went a wee bit off topic, sorry) :ghost:

and you can chain them in a doubly linked list so there shouldn’t be any hindrance in taking your project apart: let’s be a devil! :exploding_head:

How do you do that ?ive learn double link in c++ and only to get value from class object

My project is a complete mess i don’t understand anymore what i need to do and where i need to do ;-;
If this continue i will just drop it , it take to much time and never work

by reading the docs & having my hands all over Geany 1.36 :heart_eyes:

or if you don’t want to be bothered by all this push, pop & on_destroy (run ‘gb_view_botch_up’)

gb_view_botch_up.py (885 Bytes)
gb_ctrl.py (1.6 KB)

I hope a good example that not every thing that works should be done… :partying_face:

But don’t panic, even if you don’t want your separated handlers be chained there is still a way of doing it: just clear up behind you (a universally good idea) :sneezing_face:

gb_view_botch_up.py (1.0 KB)