What's wrong with keeping the switch on Gamepad Mode and just changing the visibility of the hotbars and crosshotbars via a changed /hudlayout?