Roo/bootstrap/Component.js
authorAlan Knowles <alan@roojs.com>
Thu, 21 Feb 2019 08:57:58 +0000 (16:57 +0800)
committerAlan Knowles <alan@roojs.com>
Thu, 21 Feb 2019 08:57:58 +0000 (16:57 +0800)
Roo/bootstrap/Component.js

index 419d721..30ee2ac 100644 (file)
@@ -167,13 +167,11 @@ Roo.extend(Roo.bootstrap.Component, Roo.BoxComponent,  {
      */
     addxtype  : function(tree,cntr)
     {
-        var cn = Roo.factory(tree);
-        //Roo.log(['addxtype', cn]);
-           
+        cntr = (typeof(cntr) == 'undefined' ) ? 'getChildContainer' : cntr;
+       
+       var cn = Roo.factory(tree); // this is posibly the first of two times that the ctor get's called...
         cn.parentType = this.xtype; //??
         cn.parentId = this.id;
-        
-        cntr = (typeof(cntr) == 'undefined' ) ? 'getChildContainer' : cntr;
         if (typeof(cn.container_method) == 'string') {
             cntr = cn.container_method;
         }