AssetInstaller: fix toggling dir bug, scan after install

This commit is contained in:
Poommetee Ketson 2017-05-14 20:23:28 +07:00
parent f9fc2ef83b
commit 3ee1952e39

View file

@ -184,6 +184,7 @@ void EditorAssetInstaller::open(const String &p_path, int p_depth) {
dir_map[path] = ti; dir_map[path] = ti;
ti->set_text(0, path.get_file() + "/"); ti->set_text(0, path.get_file() + "/");
ti->set_icon(0, get_icon("folder", "FileDialog")); ti->set_icon(0, get_icon("folder", "FileDialog"));
ti->set_metadata(0, String());
} else { } else {
String file = path.get_file(); String file = path.get_file();
String extension = file.get_extension().to_lower(); String extension = file.get_extension().to_lower();
@ -305,6 +306,7 @@ void EditorAssetInstaller::ok_pressed() {
if (EditorNode::get_singleton() != NULL) if (EditorNode::get_singleton() != NULL)
EditorNode::get_singleton()->show_warning("Package Installed Successfully!", "Success!"); EditorNode::get_singleton()->show_warning("Package Installed Successfully!", "Success!");
} }
EditorFileSystem::get_singleton()->scan_changes();
} }
void EditorAssetInstaller::_bind_methods() { void EditorAssetInstaller::_bind_methods() {