// wait for the handle to be signaled, return WAIT_OBJECT_0 if it is or, in
// the GUI code, WAIT_OBJECT_0 + 1 if a Windows message arrived
// wait for the handle to be signaled, return WAIT_OBJECT_0 if it is or, in
// the GUI code, WAIT_OBJECT_0 + 1 if a Windows message arrived