diff options
Diffstat (limited to 'editor/editor_file_system.h')
-rw-r--r-- | editor/editor_file_system.h | 16 |
1 files changed, 15 insertions, 1 deletions
diff --git a/editor/editor_file_system.h b/editor/editor_file_system.h index 6f4f058503..9c9076106c 100644 --- a/editor/editor_file_system.h +++ b/editor/editor_file_system.h @@ -36,7 +36,9 @@ #include "core/os/thread_safe.h" #include "core/templates/safe_refcount.h" #include "core/templates/set.h" +#include "core/templates/thread_work_pool.h" #include "scene/main/node.h" + class FileAccess; struct EditorProgressBG; @@ -214,9 +216,11 @@ class EditorFileSystem : public Node { struct ImportFile { String path; + String importer; + bool threaded = false; int order = 0; bool operator<(const ImportFile &p_if) const { - return order < p_if.order; + return order == p_if.order ? (importer < p_if.importer) : (order < p_if.order); } }; @@ -236,6 +240,16 @@ class EditorFileSystem : public Node { Set<String> group_file_cache; + ThreadWorkPool import_threads; + + struct ImportThreadData { + const ImportFile *reimport_files; + int reimport_from; + int max_index = 0; + }; + + void _reimport_thread(uint32_t p_index, ImportThreadData *p_import_data); + protected: void _notification(int p_what); static void _bind_methods(); |