MsgWaitForMultipleObjects function user32
Win32Result<WAIT_EVENT>
MsgWaitForMultipleObjects(
- int nCount,
- Pointer<
Pointer< ? pHandles,NativeType> > - bool fWaitAll,
- int dwMilliseconds,
- QUEUE_STATUS_FLAGS dwWakeMask,
Waits until one or all of the specified objects are in the signaled state or the time-out interval elapses.
The objects can include input event objects.
To learn more, see learn.microsoft.com/windows/win32/api/winuser/nf-winuser-msgwaitformultipleobjects.
Implementation
Win32Result<WAIT_EVENT> MsgWaitForMultipleObjects(
int nCount,
Pointer<Pointer>? pHandles,
bool fWaitAll,
int dwMilliseconds,
QUEUE_STATUS_FLAGS dwWakeMask,
) {
final result_ = MsgWaitForMultipleObjects_Wrapper(
nCount,
pHandles ?? nullptr,
fWaitAll ? TRUE : FALSE,
dwMilliseconds,
dwWakeMask,
);
return Win32Result(
value: WAIT_EVENT(result_.value.u32),
error: result_.error,
);
}