Added canConnectTo(otherSocket) function in NodeSocket. Currently, the only constraint is that inputs can only connect to outputs (and vice versa).
Added calls to canvas.requestPaint() when mouse interacts with nodes/sockets.
Introduced PendingConnection concept in order to get rid of the growing number of 'if' statements in Connection.
Added distinction between 'defaultColor' and 'connectedColor' in NodeSocket.