Adaptive Control for a Class of Switched Linear Systems Using State-Dependent Switching