summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--core/io/resource_importer.cpp9
-rw-r--r--core/io/resource_importer.h1
-rw-r--r--doc/classes/ScrollContainer.xml2
-rw-r--r--editor/editor_node.cpp2
-rw-r--r--editor/editor_resource_preview.cpp7
-rw-r--r--editor/editor_resource_preview.h1
-rw-r--r--editor/plugins/animation_blend_tree_editor_plugin.cpp1
-rw-r--r--scene/gui/progress_bar.cpp9
-rw-r--r--servers/visual/visual_server_viewport.cpp2
9 files changed, 24 insertions, 10 deletions
diff --git a/core/io/resource_importer.cpp b/core/io/resource_importer.cpp
index 427ce2c2cd..69907a710a 100644
--- a/core/io/resource_importer.cpp
+++ b/core/io/resource_importer.cpp
@@ -406,9 +406,14 @@ bool ResourceFormatImporter::are_import_settings_valid(const String &p_path) con
}
String ResourceFormatImporter::get_import_settings_hash() const {
+
+ Vector<Ref<ResourceImporter> > sorted_importers = importers;
+
+ sorted_importers.sort_custom<SortImporterByName>();
+
String hash;
- for (int i = 0; i < importers.size(); i++) {
- hash += ":" + importers[i]->get_importer_name() + ":" + importers[i]->get_import_settings_string();
+ for (int i = 0; i < sorted_importers.size(); i++) {
+ hash += ":" + sorted_importers[i]->get_importer_name() + ":" + sorted_importers[i]->get_import_settings_string();
}
return hash.md5_text();
}
diff --git a/core/io/resource_importer.h b/core/io/resource_importer.h
index db1befb51e..1d27d4dec3 100644
--- a/core/io/resource_importer.h
+++ b/core/io/resource_importer.h
@@ -77,7 +77,6 @@ public:
void add_importer(const Ref<ResourceImporter> &p_importer) {
importers.push_back(p_importer);
- importers.sort_custom<SortImporterByName>();
}
void remove_importer(const Ref<ResourceImporter> &p_importer) { importers.erase(p_importer); }
Ref<ResourceImporter> get_importer_by_name(const String &p_name) const;
diff --git a/doc/classes/ScrollContainer.xml b/doc/classes/ScrollContainer.xml
index 0b427fc089..c8c7fa1d01 100644
--- a/doc/classes/ScrollContainer.xml
+++ b/doc/classes/ScrollContainer.xml
@@ -4,7 +4,7 @@
A helper node for displaying scrollable elements (e.g. lists).
</brief_description>
<description>
- A ScrollContainer node with a [Control] child and scrollbar child ([HScrollBar], [VScrollBar], or both) will only draw the Control within the ScrollContainer area. Scrollbars will automatically be drawn at the right (for vertical) or bottom (for horizontal) and will enable dragging to move the viewable Control (and its children) within the ScrollContainer. Scrollbars will also automatically resize the grabber based on the minimum_size of the Control relative to the ScrollContainer. Works great with a [Panel] control. You can set EXPAND on children size flags, so they will upscale to ScrollContainer size if ScrollContainer size is bigger (scroll is invisible for chosen dimension).
+ A ScrollContainer node meant to contain a [Control] child. ScrollContainers will automatically create a scrollbar child ([HScrollBar], [VScrollBar], or both) when needed and will only draw the Control within the ScrollContainer area. Scrollbars will automatically be drawn at the right (for vertical) or bottom (for horizontal) and will enable dragging to move the viewable Control (and its children) within the ScrollContainer. Scrollbars will also automatically resize the grabber based on the minimum_size of the Control relative to the ScrollContainer. Works great with a [Panel] control. You can set EXPAND on children size flags, so they will upscale to ScrollContainer size if ScrollContainer size is bigger (scroll is invisible for chosen dimension).
</description>
<tutorials>
</tutorials>
diff --git a/editor/editor_node.cpp b/editor/editor_node.cpp
index 754e8956a1..67fba4f278 100644
--- a/editor/editor_node.cpp
+++ b/editor/editor_node.cpp
@@ -531,6 +531,8 @@ void EditorNode::_sources_changed(bool p_exist) {
if (waiting_for_first_scan) {
+ EditorResourcePreview::get_singleton()->start(); //start previes now that it's safe
+
_load_docks();
if (defer_load_scene != "") {
diff --git a/editor/editor_resource_preview.cpp b/editor/editor_resource_preview.cpp
index 1fa1fe9070..e0c292dc87 100644
--- a/editor/editor_resource_preview.cpp
+++ b/editor/editor_resource_preview.cpp
@@ -417,6 +417,10 @@ void EditorResourcePreview::check_for_invalidation(const String &p_path) {
}
}
+void EditorResourcePreview::start() {
+ ERR_FAIL_COND(thread);
+ thread = Thread::create(_thread_func, this);
+}
void EditorResourcePreview::stop() {
if (thread) {
exit = true;
@@ -428,13 +432,12 @@ void EditorResourcePreview::stop() {
}
EditorResourcePreview::EditorResourcePreview() {
+ thread = NULL;
singleton = this;
preview_mutex = Mutex::create();
preview_sem = Semaphore::create();
order = 0;
exit = false;
-
- thread = Thread::create(_thread_func, this);
}
EditorResourcePreview::~EditorResourcePreview() {
diff --git a/editor/editor_resource_preview.h b/editor/editor_resource_preview.h
index 85ac78d58f..c958bfbb74 100644
--- a/editor/editor_resource_preview.h
+++ b/editor/editor_resource_preview.h
@@ -126,6 +126,7 @@ public:
void remove_preview_generator(const Ref<EditorResourcePreviewGenerator> &p_generator);
void check_for_invalidation(const String &p_path);
+ void start();
void stop();
EditorResourcePreview();
diff --git a/editor/plugins/animation_blend_tree_editor_plugin.cpp b/editor/plugins/animation_blend_tree_editor_plugin.cpp
index eef3358260..afe2573898 100644
--- a/editor/plugins/animation_blend_tree_editor_plugin.cpp
+++ b/editor/plugins/animation_blend_tree_editor_plugin.cpp
@@ -231,6 +231,7 @@ void AnimationNodeBlendTreeEditor::_update_graph() {
}
pb->set_percent_visible(false);
+ pb->set_custom_minimum_size(Vector2(0, 14) * EDSCALE);
animations[E->get()] = pb;
node->add_child(pb);
diff --git a/scene/gui/progress_bar.cpp b/scene/gui/progress_bar.cpp
index 2195ec9778..264eda4035 100644
--- a/scene/gui/progress_bar.cpp
+++ b/scene/gui/progress_bar.cpp
@@ -39,9 +39,12 @@ Size2 ProgressBar::get_minimum_size() const {
Size2 minimum_size = bg->get_minimum_size();
minimum_size.height = MAX(minimum_size.height, fg->get_minimum_size().height);
minimum_size.width = MAX(minimum_size.width, fg->get_minimum_size().width);
- //if (percent_visible) { this is needed, else the progressbar will collapse
- minimum_size.height = MAX(minimum_size.height, bg->get_minimum_size().height + font->get_height());
- //}
+ if (percent_visible) {
+ minimum_size.height = MAX(minimum_size.height, bg->get_minimum_size().height + font->get_height());
+ } else { // this is needed, else the progressbar will collapse
+ minimum_size.width = MAX(minimum_size.width, 1);
+ minimum_size.height = MAX(minimum_size.height, 1);
+ }
return minimum_size;
}
diff --git a/servers/visual/visual_server_viewport.cpp b/servers/visual/visual_server_viewport.cpp
index d6e43b0f00..2c6709662f 100644
--- a/servers/visual/visual_server_viewport.cpp
+++ b/servers/visual/visual_server_viewport.cpp
@@ -167,7 +167,7 @@ void VisualServerViewport::_draw_viewport(Viewport *p_viewport, ARVRInterface::E
RasterizerCanvas::Light *light = lights_with_shadow;
while (light) {
- VSG::canvas_render->canvas_light_shadow_buffer_update(light->shadow_buffer, light->xform_cache.affine_inverse(), light->item_mask, light->radius_cache / 1000.0, light->radius_cache * 1.1, occluders, &light->shadow_matrix_cache);
+ VSG::canvas_render->canvas_light_shadow_buffer_update(light->shadow_buffer, light->xform_cache.affine_inverse(), light->item_shadow_mask, light->radius_cache / 1000.0, light->radius_cache * 1.1, occluders, &light->shadow_matrix_cache);
light = light->shadows_next_ptr;
}