Added behaviour to some buttons.