Fixed ordinging of item actions.

Also made it impossible to have unvalid options selected. (I think)