Adding nodes
andreasplesch opened this issue · 3 comments
andreasplesch commented
Parser.pushParent(elparent.x3dnode)
Should suffice to parse new node into parent with Parser.statement()
If no parent, eg root node just skip push parent
Then perhaps necessary to popParent
but new Parser is created with empty parents [] for each mutation. but it is possible to have multiple added nodes in one mutation.
andreasplesch commented
parser.statement() works fine but it is still necessary to .setValue of the parent field.
andreasplesch commented
How to determine correct execution context?
Use parent's if it exists, eg. Non root node.
If root node, find closest inline and use getInternalScene.
andreasplesch commented
Root node.parent.parent.name == inline
Parser.pushexecutioncontext(inline.node.getInternalScene)