It seems that I had the wrong idea about how window class registration in Windows works. The window class you register in a DLL is not shared by all processes that use the DLL so you only need to concern yourself about what the current process is doing.

There could still be issues if the process that is using your DLL is manually loading and unloading your DLL so you're basically forced to implement an init and corresponding uninit function and specificy that they must be called after (before) you call LoadLibrary (FreeLibrary).