add switch window code