I'm having a problem similar to the one here about window focus. A little while after starting Photoshop or Lightroom, the mouse can only cause one window to be focused. It seems to happen less than 30 minutes after starting, whether the program is still open or not. The window that the mouse is bound to seems to be the one that's focused when the issue begins, although it's hard to tell. This persists across multiple desktops, so on all but one desktop, none of the windows can be interacted with.
If I close the bound window, the mouse is stuck with the next active window. This is a mouse-only problem and affects both the trackpad and my wireless mouse. Disconnecting and reconnecting does nothing. The keyboard works completely fine. If I alt-tab to another window, and then click anywhere, the stuck window regains focus. Restarting explorer.exe does nothing.
The easiest solution I have is putting the computer to sleep and waking it back up. I'm looking for a way to prevent this from happening.
To reproduce, I open Lightroom or Photoshop, then use my computer normally for a while. The issue arises over 50% of the time.