Created by: zeffii
This demonstrates the slightly obscure way to dynamically populate menus, there are pros and cons to this approach. I will focus on the positive.. this lets us totally hot-evaluate a new menu and submenus.
to test, switch to this branch
- hit
f3and typepop....ulate , it will show thepopulate lite menuoperator behind the scenes this populates a CollectionProperty with items, all of which contain a StringProperty calleditem.heading, these headings are used as a submenu lookup. - hit ctrl+shift+
](right bracket) this will display a menu, with submenus (that are justlayout.labelsfor now.
the cons of this approach are, the menu must be populated once per active node_tree. I suspect this could be done in the builtin nodetree update function...