added extra_button_function option