added Listeners for buttons