Reorganized some ui and added support for key