The primary motivation for this is that NVDA starts a lot earlier after logging on in Windows 8 and later. However, it should also be more reliable and future proof than using our own service. Also, this means NVDA is now listed in the Ease of Access Center on Windows 8 and later.
Note that in Windows Vista and 7, Ease of Access can't be instructed not to terminate ATs on every desktop switch, so we use a proxy process. Unfortunately, Windows also terminates child processes, so we can't use EoA to start NVDA on non-secure desktops at all. Because of this, we don't show it to the user in the EoA Center at all.
Some other noteworthy changes that were needed:
- Rather than specifying command line options from the service when starting NVDA on the secure desktop, make NVDA itself detect this and set the appropriate options. This is needed for Ease of Access, where there is no elegant way to pass different options for secure desktops.
- Use the name of the input desktop for the main thread instead of the current input desktop for the startup mutex. This is particularly important because EoA can sometimes start NVDA on the default desktop before switching to it.
- When NVDA has uiAccess, don't show and hide our window on startup, as this messes with the focus and causes focus to be moved out of the Start Screen in Windows 8/8.1. uiAccess allows us to always come to the foreground anyway.