Merge pull request #62827 from fire-forge/ok-cancel

Add `ok_button_text` to AcceptDialog and `cancel_button_text` to ConfirmationDialog
This commit is contained in:
Rémi Verschelde 2022-07-13 14:10:38 +02:00 committed by GitHub
commit b942c1ffe3
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
59 changed files with 188 additions and 149 deletions

View file

@ -1688,7 +1688,7 @@ AnimationPlayerEditor::AnimationPlayerEditor(AnimationPlayerEditorPlugin *p_plug
name_dialog->register_text_enter(name);
error_dialog = memnew(ConfirmationDialog);
error_dialog->get_ok_button()->set_text(TTR("Close"));
error_dialog->set_ok_button_text(TTR("Close"));
error_dialog->set_title(TTR("Error!"));
add_child(error_dialog);
@ -1696,7 +1696,7 @@ AnimationPlayerEditor::AnimationPlayerEditor(AnimationPlayerEditorPlugin *p_plug
blend_editor.dialog = memnew(AcceptDialog);
add_child(blend_editor.dialog);
blend_editor.dialog->get_ok_button()->set_text(TTR("Close"));
blend_editor.dialog->set_ok_button_text(TTR("Close"));
blend_editor.dialog->set_hide_on_ok(true);
VBoxContainer *blend_vb = memnew(VBoxContainer);
blend_editor.dialog->add_child(blend_vb);