changes to switch control