Mouse viewport bug with dual monitors

Okay so I finally figured out this frustrating bug, should be easy to reproduce. Hold down right mouse to control the viewport as usual, but then move your mouse to the far right or left, where your other monitor is, and you’re able to scroll on those windows instead of the scroll adjusting the speed of the viewport camera. The mouse doesn’t show up on the other monitor, but it acts like it’s there. Would appreciate a fix or any tips to solve this, thanks.