From 188ccf190ba398ef9d3f661016f15cc005505c26 Mon Sep 17 00:00:00 2001 From: ShyRed Date: Sat, 10 Mar 2018 14:21:17 +0100 Subject: [PATCH] Update preview on filesystem change Check and recreate a file's preview, if it has changes to it in the filesystem. --- editor/editor_file_system.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/editor/editor_file_system.cpp b/editor/editor_file_system.cpp index dca32d74925..15aa2c3a0e1 100644 --- a/editor/editor_file_system.cpp +++ b/editor/editor_file_system.cpp @@ -1316,6 +1316,9 @@ void EditorFileSystem::update_file(const String &p_file) { fs->files[cpos]->deps = _get_dependencies(p_file); fs->files[cpos]->import_valid = ResourceLoader::is_import_valid(p_file); + // Update preview + EditorResourcePreview::get_singleton()->check_for_invalidation(p_file); + call_deferred("emit_signal", "filesystem_changed"); //update later }