Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJacques Lucke <jacques@blender.org>2021-10-25 12:30:41 +0300
committerJacques Lucke <jacques@blender.org>2021-10-25 12:30:41 +0300
commit1ecb4e6fd8fcde581c8d79d9750a147361fa6915 (patch)
treeb2cbf4715d1534fbdf38c85d126bf50feb09f78b /source/blender
parent15762e961127fb8fbde1855311e01f99dfe5677e (diff)
Fix T92446: node editor overlays reset automatically
Caused by rBcf72b10075758be971f9806b97db01f98383aba2. The fix is to only enable the flags when a new node editor is actually created.
Diffstat (limited to 'source/blender')
-rw-r--r--source/blender/editors/space_node/space_node.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/source/blender/editors/space_node/space_node.c b/source/blender/editors/space_node/space_node.c
index bd2559c4d4d..8c015a56fa1 100644
--- a/source/blender/editors/space_node/space_node.c
+++ b/source/blender/editors/space_node/space_node.c
@@ -92,9 +92,6 @@ void ED_node_tree_start(SpaceNode *snode, bNodeTree *ntree, ID *id, ID *from)
snode->id = id;
snode->from = from;
- snode->overlay.flag |= SN_OVERLAY_SHOW_OVERLAYS;
- snode->overlay.flag |= SN_OVERLAY_SHOW_WIRE_COLORS;
-
ED_node_set_active_viewer_key(snode);
WM_main_add_notifier(NC_SCENE | ND_NODES, NULL);
@@ -259,6 +256,8 @@ static SpaceLink *node_create(const ScrArea *UNUSED(area), const Scene *UNUSED(s
snode->spacetype = SPACE_NODE;
snode->flag = SNODE_SHOW_GPENCIL | SNODE_USE_ALPHA;
+ snode->overlay.flag |= SN_OVERLAY_SHOW_OVERLAYS;
+ snode->overlay.flag |= SN_OVERLAY_SHOW_WIRE_COLORS;
/* backdrop */
snode->zoom = 1.0f;