It's really on-brand for Microsoft Windows APIs. They're all about making you fill out a giant tax form of a struct and passing the OS a callback. It's kind of a house style that Microsoft adopted back in the Windows 3.x or before days and it stuck.
My favorite is the Dir() function in Visual Basic which is used for directory walking. Only it's non-reentrant, so you can't walk subdirectories with it! Near as I can tell it's traceable back to DIR$ in GW-BASIC, which in turn was an exposure of DOS's broken, non-reentrant GetDirectoryEntry and NextDirectoryEntry system calls! DOS will just never die!