// Just process children protected override DomNode Convert(DomDocument document, DomElement element, IScriptGenerator gen) { var e = document.CreateElement(element.Name); // Copy annotations to the new element e.AddAnnotations(element.Annotations <object>().Except(HxlAnnotations.Retained)); return(ProcessChildren(e, element, gen)); }
protected override void VisitElement(DomElement element) { string varName = SafeNewVariable(element.Name); CurrentOutput.WriteLine( "{1} = this.__document.CreateElement(\"{0}\");", element.Name, varName); foreach (var m in element.Annotations <IRenderWorkElementCodeBuilder>()) { m.EmitCode(output, varName, element); } DoChildVisit(element, varName); DoAppend(varName); }