1
0
mirror of https://github.com/godotengine/godot.git synced 2025-11-05 12:10:55 +00:00

Merge pull request #75137 from nongvantinh/implement-6320

Expose 'Reimport' on right-click context menu in the FileSystem panel
This commit is contained in:
Rémi Verschelde
2023-08-07 14:43:44 +02:00
3 changed files with 48 additions and 7 deletions

View File

@@ -324,6 +324,21 @@ void ImportDock::set_edit_multiple_paths(const Vector<String> &p_paths) {
}
}
void ImportDock::reimport_resources(const Vector<String> &p_paths) {
switch (p_paths.size()) {
case 0:
ERR_FAIL_MSG("You need to select files to reimport them.");
case 1:
set_edit_path(p_paths[0]);
break;
default:
set_edit_multiple_paths(p_paths);
break;
}
_reimport_attempt();
}
void ImportDock::_update_preset_menu() {
preset->get_popup()->clear();