Cleaner way to detect connections changing

for render image purposes.  This commit improves on the changes
made in 5b0a3678ef729bfcab35e655411 and 507c15c25ce4c554d8843afe.