Changing States

I have a course settings tab that changes the background colour when the user clicks on a button. I've added a selected state to the button so it looks like it is pushed in when selected. When you select another button the button that was selected returns to normal.

The buttons are Orange, blue, yellow and white.

These work fine apart from when I click the blue, yellow or white button before selecting the orange button. When I do this the previous colour stays selected. 

Any ideas what is going on?

3 Replies