fixed res switcher, used regexp's