Ah, I figured out what was going on.
My mouse is usually connected to my computer via a USB receiver, but the mouse's connection somehow got switched to bluetooth.
Once I switched the connection mode back to the USB receiver, everything started working again as normal.