summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRĂ©mi Verschelde <rverschelde@gmail.com>2017-11-17 09:22:23 +0100
committerGitHub <noreply@github.com>2017-11-17 09:22:23 +0100
commit64caa4733caa459f2dc2eb6eecf88053fa6a484b (patch)
treeebb5471dcff36ed50feeb5190200812d68ead169
parentb44cb4e3b9b573a3cbbd6f71aff81e6c3465d84b (diff)
parent496e4e0d2f310fe603cd683c197e247431a48b4a (diff)
Merge pull request #12977 from YeldhamDev/create_node_relationships
Enabling relationship lines in the Scene Tree enables them in the Create New Node dialog as well
-rw-r--r--editor/create_dialog.cpp9
1 files changed, 9 insertions, 0 deletions
diff --git a/editor/create_dialog.cpp b/editor/create_dialog.cpp
index 95b4f7e982..02af304dc6 100644
--- a/editor/create_dialog.cpp
+++ b/editor/create_dialog.cpp
@@ -97,6 +97,15 @@ void CreateDialog::popup_create(bool p_dontclear) {
search_box->grab_focus();
_update_search();
+
+ bool enable_rl = EditorSettings::get_singleton()->get("docks/scene_tree/draw_relationship_lines");
+ Color rl_color = EditorSettings::get_singleton()->get("docks/scene_tree/relationship_line_color");
+
+ if (enable_rl) {
+ search_options->add_constant_override("draw_relationship_lines", 1);
+ search_options->add_color_override("relationship_line_color", rl_color);
+ } else
+ search_options->add_constant_override("draw_relationship_lines", 0);
}
void CreateDialog::_text_changed(const String &p_newtext) {