Saturday, September 28, 2013

Empty group sockets

Sometimes when working with groups you end up with a few empty sockets inside the group and there is no button to remove these empty sockets (we may eventually add one).



But there is a way to get rid of them.

Empty sockets are removed during saving/Loading (saving and then loading the group or the scene).
So when you reload the group/scene the empty sockets will be gone, if the following conditions are met:

1. The label of the socket is empty (so it displays "any" as its label in the view)
2. There are no used sockets below it.
3. It is not the only empty socket (we always keep one empty socket)

Number 1 and 2 are are probably not that obvious, but the reason for it was if the user is in the middle of creating groups and saves a scene and goes home for the day, you don't want to loose your work and have to redo labeling or organizing your sockets.

In order to ensure a socket gets removed, you have to use the "Move Socket Up" button on any used sockets below it. (Which can also be a bit tedious to use at times, but it is what we have right now)

Here is the corrected group for which the unused sockets will get removed after save/load.
(Except for 1 'any' socket since we always keep one for users to add new connections)