var TcHmi;!function(TcHmi){!function(Controls){!function(System){class TcHmiContainer extends TcHmi.Controls.System.TcHmiContainerControl{constructor(element,pcElement,attrs){super(element,pcElement,attrs)}__previnit(){if(this.__elementTemplateRoot=this.__element.find(".TcHmi_Controls_System_TcHmiContainer-template"),0===this.__elementTemplateRoot.length&&(this.__elementTemplateRoot=this.__element.find(".tchmi-container-template")),0===this.__elementTemplateRoot.length)throw new Error("Invalid Template.html");super.__previnit()}__init(){super.__init();for(let i=0,ii=this.__children.length;i<ii;i++)this.__elementTemplateRoot[0].appendChild(this.__children[i].getElement()[0])}__attach(){super.__attach()}__detach(){super.__detach()}destroy(){this.__keepAlive||super.destroy()}addChild(control,pos){control&&this.__addChild(control,pos)}__addChild(control,pos){if(super.__addChild(control,pos),null==pos||pos<0)return void this.__elementTemplateRoot[0].appendChild(control.getElement()[0]);if(0===pos)return void this.__elementTemplateRoot.prepend(control.getElement());const prev=this.__elementTemplateRoot.children().eq(pos-1);0===prev.length?this.__elementTemplateRoot[0].appendChild(control.getElement()[0]):prev.after(control.getElement())}removeChild(control){control&&this.__removeChild(control)}__removeChild(control){super.__removeChild(control)}}System.TcHmiContainer=TcHmiContainer}(Controls.System||(Controls.System={}))}(TcHmi.Controls||(TcHmi.Controls={}))}(TcHmi||(TcHmi={})),TcHmi.Controls.registerEx("TcHmiContainer","TcHmi.Controls.System",TcHmi.Controls.System.TcHmiContainer);