Added pop-up selectors, tidied things up a bit.