Your mouse will glide if your driver is broken or outdated. You might see your mouse cursor moving automatically due to this in-game and in the normal state. The solution would be to update the driver.