Fix #35640, part 1. Set the id.lib pointer for nested bNodeTree data blocks inside material, scene, etc. on lib_link, so that the UI buttons get disabled when editing linked node trees. Thanks to Brecht
van Lommel for suggesting this fix.

git-svn-id: https://svn.blender.org/svnroot/bf-blender/trunk/blender@57252 954f8c5b-7b00-dc11-b283-0030488c597c
Fix #35640, part 2. Check id.lib in poll functions for operators which do critical modification of node trees (create nodes, link, etc.). Transform operators and hide/show type operators are still
allowed, this does not modify actual behavior of the nodes and can be useful for inspecting linked nodes.

git-svn-id: https://svn.blender.org/svnroot/bf-blender/trunk/blender@57253 954f8c5b-7b00-dc11-b283-0030488c597c