Switch from one command to another without intermediate "stop" click

I don't know if it's intended behavior or not, but clicking on a button when another is selected just stops the current command, but doesn't start the one corresponding to the button. This fixes the problem by stopping the current command as soon as the button is pressed down.