Added ActionListeners to buttons.