Adding setTriggerForIndex method to ControlSwitcher.