summaryrefslogtreecommitdiffstats
path: root/editor/localization_editor.cpp
diff options
context:
space:
mode:
authorRémi Verschelde <rverschelde@gmail.com>2021-07-24 15:46:25 +0200
committerRémi Verschelde <rverschelde@gmail.com>2021-07-25 12:22:25 +0200
commitac3322b0af8f23e8e2dac8111200bc69b5604c9f (patch)
tree59a079f13b5c03c2dd3328a26c55f3618e6014f6 /editor/localization_editor.cpp
parenta0f7f42b842462646281f5c4c9a8db070e034adc (diff)
downloadredot-engine-ac3322b0af8f23e8e2dac8111200bc69b5604c9f.tar.gz
Use const references where possible for List range iterators
Diffstat (limited to 'editor/localization_editor.cpp')
-rw-r--r--editor/localization_editor.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/editor/localization_editor.cpp b/editor/localization_editor.cpp
index d4b712b6a3..b32ea67d4d 100644
--- a/editor/localization_editor.cpp
+++ b/editor/localization_editor.cpp
@@ -43,13 +43,13 @@ void LocalizationEditor::_notification(int p_what) {
List<String> tfn;
ResourceLoader::get_recognized_extensions_for_type("Translation", &tfn);
- for (String &E : tfn) {
+ for (const String &E : tfn) {
translation_file_open->add_filter("*." + E);
}
List<String> rfn;
ResourceLoader::get_recognized_extensions_for_type("Resource", &rfn);
- for (String &E : rfn) {
+ for (const String &E : rfn) {
translation_res_file_open_dialog->add_filter("*." + E);
translation_res_option_file_open_dialog->add_filter("*." + E);
}
@@ -430,7 +430,7 @@ void LocalizationEditor::_update_pot_file_extensions() {
pot_file_open_dialog->clear_filters();
List<String> translation_parse_file_extensions;
EditorTranslationParser::get_singleton()->get_recognized_extensions(&translation_parse_file_extensions);
- for (String &E : translation_parse_file_extensions) {
+ for (const String &E : translation_parse_file_extensions) {
pot_file_open_dialog->add_filter("*." + E);
}
}
@@ -560,7 +560,7 @@ void LocalizationEditor::update_translations() {
List<Variant> rk;
remaps.get_key_list(&rk);
Vector<String> keys;
- for (Variant &E : rk) {
+ for (const Variant &E : rk) {
keys.push_back(E);
}
keys.sort();