Add add_button function to a given popup