Earlier quoted context omitted.
That is incidentally one of the many papercuts that are widely accepted in Windows, but never were a problem on a mac. Don’t try to interact with a windows desktop while it is still booting up. Better to wait for everything to settle down, otherwise apps will constantly snatch away focus and your typing will go into random applications.
This is a constant irritation for me on Windows. I work on a desktop Windows/Mac application that takes forever and a day to launch (CAD package), and pops up a million pop-ups during the process. I try to get minor admin tasks done while it is compiling/launching, but it steals focus every 10 seconds! Still beats using XCode, though
by default if you haven't typed anything for a little bit Windows allows an application to steal focus. If you change that value you can prevent windows from ever stealing focus or change how long they have to wait before they're allowed to.