2 ms·
Yes, but the inversion of control is unpleasant to deal with—compare Find{First,Next}File which don’t require that.
by mananaysiempre 2y ago
Yes, but the inversion of control is unpleasant to deal with—compare Find{First,Next}File which don’t require that.
- wongarsu 2y agoWhich is a pattern that also exists in the Win32 API, for example in the handle = CreateToolhelp32Snapshot(), Thread32First(handle, out), while Thread32Next(handle, out) API for iterating over a process's threads. I also find EnumChildWindows pretty wacky. It's not too bad to use, but it's a weird pattern and a pattern that Windows has also moved away from since XP. https://learn.microsoft.com/en-us/windows/win32/toolhelp/traversing-the-thread-list https://learn.microsoft.com/en-us/windows/win32/toolhelp/tra...