Add EditorStringNames singleton

This commit is contained in:
kobewi 2023-08-13 02:33:39 +02:00
parent fa3428ff25
commit 6de34fde27
176 changed files with 2549 additions and 2325 deletions

View file

@ -497,7 +497,7 @@ void LocalizationEditor::update_translations() {
t->set_text(0, translations[i].replace_first("res://", ""));
t->set_tooltip_text(0, translations[i]);
t->set_metadata(0, i);
t->add_button(0, get_theme_icon(SNAME("Remove"), SNAME("EditorIcons")), 0, false, TTR("Remove"));
t->add_button(0, get_editor_theme_icon(SNAME("Remove")), 0, false, TTR("Remove"));
}
}
@ -531,7 +531,7 @@ void LocalizationEditor::update_translations() {
t->set_text(0, keys[i].replace_first("res://", ""));
t->set_tooltip_text(0, keys[i]);
t->set_metadata(0, keys[i]);
t->add_button(0, get_theme_icon(SNAME("Remove"), SNAME("EditorIcons")), 0, false, TTR("Remove"));
t->add_button(0, get_editor_theme_icon(SNAME("Remove")), 0, false, TTR("Remove"));
// Display that it has been removed if this is the case.
if (!FileAccess::exists(keys[i])) {
@ -555,7 +555,7 @@ void LocalizationEditor::update_translations() {
t2->set_text(0, path.replace_first("res://", ""));
t2->set_tooltip_text(0, path);
t2->set_metadata(0, j);
t2->add_button(0, get_theme_icon(SNAME("Remove"), SNAME("EditorIcons")), 0, false, TTR("Remove"));
t2->add_button(0, get_editor_theme_icon(SNAME("Remove")), 0, false, TTR("Remove"));
t2->set_cell_mode(1, TreeItem::CELL_MODE_CUSTOM);
t2->set_text(1, TranslationServer::get_singleton()->get_locale_name(locale));
t2->set_editable(1, true);
@ -583,7 +583,7 @@ void LocalizationEditor::update_translations() {
t->set_text(0, pot_translations[i].replace_first("res://", ""));
t->set_tooltip_text(0, pot_translations[i]);
t->set_metadata(0, i);
t->add_button(0, get_theme_icon(SNAME("Remove"), SNAME("EditorIcons")), 0, false, TTR("Remove"));
t->add_button(0, get_editor_theme_icon(SNAME("Remove")), 0, false, TTR("Remove"));
}
// New translation parser plugin might extend possible file extensions in POT generation.