[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: New control structure "Do Next..."
[Thread Prev] | [Thread Next]
- Subject: Re: New control structure "Do Next..."
- From: Benoît Minisini <benoit.minisini@xxxxxxxxxxxxxxxx>
- Date: Sat, 17 May 2025 12:39:42 +0200
- To: user@xxxxxxxxxxxxxxxxxxxxxx
Le 17/05/2025 à 10:29, Fabien Bodard a écrit :
Hem...I understand the idea as the procedure is like stored in a trigger array for post activation.So the loop continue until the end and then the procedure is called. But I don't understand the need.
I use this pattern for a lot of things, especially with GUI toolkits. For example :
- Raising a Click event outside of a MouseDown event handler.- Reparenting a window after it has been closed, because GUI toolkits seems not to like reparenting directly in the Close event handler.
- Raise a "Modified" event once, and not for each modification during the same event loop.
...and so on.It's funny that you don't understand the need, whereas you wrote the DocumentView class which uses this pattern constantly. Just search for the "Trigger" method applied on Timers. There are fourteen occurrences!
Regards, -- Benoît Minisini.
Re: New control structure "Do Next..." | Fabien Bodard <gambas.fr@xxxxxxxxx> |
New control structure "Do Next..." | Benoît Minisini <benoit.minisini@xxxxxxxxxxxxxxxx> |
Re: New control structure "Do Next..." | Jorge Carrión <shordi@xxxxxxxxx> |
Re: New control structure "Do Next..." | Fabien Bodard <gambas.fr@xxxxxxxxx> |