Some ui refactoring.