Bug 937306: Improvements to WinUtils::WaitForMessage; r=jimm, a=sylvestre