updated

added buttons and cleaned up code