cleanup and got the buttons working