소스 검색

Merge pull request #62333 from timothyqiu/ani-title

[3.x] Fix prompt dialog title for Animation operations
Rémi Verschelde 3 년 전
부모
커밋
a01f67202d
1개의 변경된 파일3개의 추가작업 그리고 1개의 파일을 삭제
  1. 3 1
      editor/plugins/animation_player_editor_plugin.cpp

+ 3 - 1
editor/plugins/animation_player_editor_plugin.cpp

@@ -327,6 +327,7 @@ void AnimationPlayerEditor::_animation_new() {
 	}
 
 	name->set_text(base);
+	name_dialog->set_title(TTR("Create New Animation"));
 	name_dialog->popup_centered(Size2(300, 90));
 	name->select_all();
 	name->grab_focus();
@@ -341,6 +342,7 @@ void AnimationPlayerEditor::_animation_rename() {
 	name_title->set_text(TTR("Change Animation Name:"));
 	name->set_text(selected_name);
 	name_dialog_op = TOOL_RENAME_ANIM;
+	name_dialog->set_title(TTR("Rename Animation"));
 	name_dialog->popup_centered(Size2(300, 90));
 	name->select_all();
 	name->grab_focus();
@@ -1005,6 +1007,7 @@ void AnimationPlayerEditor::_animation_duplicate() {
 	name_title->set_text(TTR("New Animation Name:"));
 	name->set_text(new_name);
 	name_dialog_op = TOOL_DUPLICATE_ANIM;
+	name_dialog->set_title(TTR("Duplicate Animation"));
 	name_dialog->popup_centered(Size2(300, 90));
 	name->select_all();
 	name->grab_focus();
@@ -1697,7 +1700,6 @@ AnimationPlayerEditor::AnimationPlayerEditor(EditorNode *p_editor, AnimationPlay
 	add_child(file);
 
 	name_dialog = memnew(ConfirmationDialog);
-	name_dialog->set_title(TTR("Create New Animation"));
 	name_dialog->set_hide_on_ok(false);
 	add_child(name_dialog);
 	VBoxContainer *vb = memnew(VBoxContainer);