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:
authorJuho Vepsalainen <bebraw@gmail.com>2007-12-28 11:04:37 +0300
committerJuho Vepsalainen <bebraw@gmail.com>2007-12-28 11:04:37 +0300
commit4a0dc8d4d94f10b93de4a8bf4441e466da70a64b (patch)
tree249e308a686b977f8e37ade1c5a08ce4c3d90d03 /source/blender/blenloader/intern
parent16ea99cbaa95b86fc02d92ad5a5e46558d7f1ae6 (diff)
Bugfix - Socket selection status was not updated properly on file load
This commit adds a missing initialization that caused "Toggle Link (f key)" not to work properly in case a file with an existing selection status was opened.
Diffstat (limited to 'source/blender/blenloader/intern')
-rw-r--r--source/blender/blenloader/intern/readfile.c16
1 files changed, 16 insertions, 0 deletions
diff --git a/source/blender/blenloader/intern/readfile.c b/source/blender/blenloader/intern/readfile.c
index 043febbbc75..a886c0d195b 100644
--- a/source/blender/blenloader/intern/readfile.c
+++ b/source/blender/blenloader/intern/readfile.c
@@ -1524,6 +1524,22 @@ static void direct_link_nodetree(FileData *fd, bNodeTree *ntree)
link->tosock= newdataadr(fd, link->tosock);
}
+ /* set selin and selout */
+ for(node= ntree->nodes.first; node; node= node->next) {
+ for(sock= node->inputs.first; sock; sock= sock->next) {
+ if(sock->flag & SOCK_SEL) {
+ ntree->selin= sock;
+ break;
+ }
+ }
+ for(sock= node->outputs.first; sock; sock= sock->next) {
+ if(sock->flag & SOCK_SEL) {
+ ntree->selout= sock;
+ break;
+ }
+ }
+ }
+
/* type verification is in lib-link */
}