mirror of
https://github.com/godotengine/godot.git
synced 2026-01-06 10:11:57 +03:00
[iOS] Fix plugin configuration loading
Clear ConfigFile parameter before loading new file.
Ignore duplicate input plist keys
(cherry picked from commit aa321f0a24)
This commit is contained in:
committed by
Rémi Verschelde
parent
72db6016ba
commit
f3da335416
@@ -372,6 +372,8 @@ void EditorExportPlatformIOS::get_export_options(List<ExportOption> *r_options)
|
||||
r_options->push_back(ExportOption(PropertyInfo(Variant::BOOL, "plugins/" + found_plugins[i].name), false));
|
||||
}
|
||||
|
||||
Set<String> plist_keys;
|
||||
|
||||
for (int i = 0; i < found_plugins.size(); i++) {
|
||||
// Editable plugin plist values
|
||||
PluginConfigIOS plugin = found_plugins[i];
|
||||
@@ -383,7 +385,10 @@ void EditorExportPlatformIOS::get_export_options(List<ExportOption> *r_options)
|
||||
switch (item.type) {
|
||||
case PluginConfigIOS::PlistItemType::STRING_INPUT: {
|
||||
String preset_name = "plugins_plist/" + key;
|
||||
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, preset_name), item.value));
|
||||
if (!plist_keys.has(preset_name)) {
|
||||
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, preset_name), item.value));
|
||||
plist_keys.insert(preset_name);
|
||||
}
|
||||
} break;
|
||||
default:
|
||||
continue;
|
||||
|
||||
Reference in New Issue
Block a user