Skip to content

Commit a595ae2

Browse files
committed
Merge pull request godotengine#97461 from lalitshankarchowdhury/better-replace
Improve "Replace in Files" dialog button text
2 parents 5dbc5af + b9ce6c9 commit a595ae2

File tree

2 files changed

+16
-12
lines changed

2 files changed

+16
-12
lines changed

editor/editor_node.cpp

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -7706,24 +7706,28 @@ EditorNode::EditorNode() {
77067706

77077707
disk_changed = memnew(ConfirmationDialog);
77087708
{
7709-
disk_changed->set_title(TTR("Files have been modified on disk"));
7709+
disk_changed->set_title(TTR("Files have been modified outside Godot"));
77107710

77117711
VBoxContainer *vbc = memnew(VBoxContainer);
77127712
disk_changed->add_child(vbc);
77137713

77147714
Label *dl = memnew(Label);
7715-
dl->set_text(TTR("The following files are newer on disk.\nWhat action should be taken?"));
7715+
dl->set_text(TTR("The following files are newer on disk:"));
77167716
vbc->add_child(dl);
77177717

77187718
disk_changed_list = memnew(Tree);
77197719
vbc->add_child(disk_changed_list);
77207720
disk_changed_list->set_v_size_flags(Control::SIZE_EXPAND_FILL);
77217721

7722+
Label *what_action_label = memnew(Label);
7723+
what_action_label->set_text(TTR("What action should be taken?"));
7724+
vbc->add_child(what_action_label);
7725+
77227726
disk_changed->connect(SceneStringName(confirmed), callable_mp(this, &EditorNode::_reload_modified_scenes));
77237727
disk_changed->connect(SceneStringName(confirmed), callable_mp(this, &EditorNode::_reload_project_settings));
7724-
disk_changed->set_ok_button_text(TTR("Discard local changes and reload"));
7728+
disk_changed->set_ok_button_text(TTR("Reload from disk"));
77257729

7726-
disk_changed->add_button(TTR("Keep local changes and overwrite"), !DisplayServer::get_singleton()->get_swap_cancel_ok(), "resave");
7730+
disk_changed->add_button(TTR("Ignore external changes"), !DisplayServer::get_singleton()->get_swap_cancel_ok(), "resave");
77277731
disk_changed->connect("custom_action", callable_mp(this, &EditorNode::_resave_scenes));
77287732
}
77297733

editor/plugins/script_editor_plugin.cpp

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -4391,28 +4391,28 @@ ScriptEditor::ScriptEditor(WindowWrapper *p_wrapper) {
43914391

43924392
disk_changed = memnew(ConfirmationDialog);
43934393
{
4394-
disk_changed->set_title(TTR("Files have been modified on disk"));
4394+
disk_changed->set_title(TTR("Files have been modified outside Godot"));
43954395

43964396
VBoxContainer *vbc = memnew(VBoxContainer);
43974397
disk_changed->add_child(vbc);
43984398

43994399
Label *files_are_newer_label = memnew(Label);
4400-
files_are_newer_label->set_text(TTR("The following files are newer on disk."));
4400+
files_are_newer_label->set_text(TTR("The following files are newer on disk:"));
44014401
vbc->add_child(files_are_newer_label);
44024402

4403-
Label *what_action_label = memnew(Label);
4404-
what_action_label->set_text(TTR("What action should be taken?:"));
4405-
vbc->add_child(what_action_label);
4406-
44074403
disk_changed_list = memnew(Tree);
44084404
vbc->add_child(disk_changed_list);
44094405
disk_changed_list->set_auto_translate_mode(AUTO_TRANSLATE_MODE_DISABLED);
44104406
disk_changed_list->set_v_size_flags(SIZE_EXPAND_FILL);
44114407

4408+
Label *what_action_label = memnew(Label);
4409+
what_action_label->set_text(TTR("What action should be taken?"));
4410+
vbc->add_child(what_action_label);
4411+
44124412
disk_changed->connect(SceneStringName(confirmed), callable_mp(this, &ScriptEditor::reload_scripts).bind(false));
4413-
disk_changed->set_ok_button_text(TTR("Discard local changes and reload"));
4413+
disk_changed->set_ok_button_text(TTR("Reload from disk"));
44144414

4415-
disk_changed->add_button(TTR("Keep local changes and overwrite"), !DisplayServer::get_singleton()->get_swap_cancel_ok(), "resave");
4415+
disk_changed->add_button(TTR("Ignore external changes"), !DisplayServer::get_singleton()->get_swap_cancel_ok(), "resave");
44164416
disk_changed->connect("custom_action", callable_mp(this, &ScriptEditor::_resave_scripts));
44174417
}
44184418

0 commit comments

Comments
 (0)