summaryrefslogtreecommitdiff
path: root/tools
diff options
context:
space:
mode:
authorBojidar Marinov <bojidar.marinov.bg@gmail.com>2016-06-09 23:08:45 +0300
committerBojidar Marinov <bojidar.marinov.bg@gmail.com>2016-06-09 23:08:45 +0300
commitc63ec998be918ada277d381520d6324a40325409 (patch)
treea0185582ade33b1ac7e528cd8f68ec29f3ca9884 /tools
parenta3890594fa2798ef31d92e4195c84b7246860929 (diff)
Update asset library assets only when opening the respective tab
Diffstat (limited to 'tools')
-rw-r--r--tools/editor/asset_library_editor_plugin.cpp6
1 files changed, 5 insertions, 1 deletions
diff --git a/tools/editor/asset_library_editor_plugin.cpp b/tools/editor/asset_library_editor_plugin.cpp
index 928acdbcbb..c571310ded 100644
--- a/tools/editor/asset_library_editor_plugin.cpp
+++ b/tools/editor/asset_library_editor_plugin.cpp
@@ -541,8 +541,12 @@ void EditorAssetLibrary::_notification(int p_what) {
error_hb->add_child(tf);
error_label->raise();
+ }
- _repository_changed(0);
+ if (p_what==NOTIFICATION_VISIBILITY_CHANGED) {
+ if(!is_hidden()) {
+ _repository_changed(0); // Update when shown for the first time
+ }
}
if (p_what==NOTIFICATION_PROCESS) {