Main loop fixes/cleanup Tidy up win32 main loop bits, allow timeout >= 1s, and force timeout to 0 if there is a pending bottom half.
Changed paths: