Alexandre Julliard : user32/tests: Only check the foreground window when it belongs to the current thread.