Uncommited changes synced
authorAlan Knowles <alan@roojs.com>
Wed, 9 Jan 2019 10:06:12 +0000 (18:06 +0800)
committerAlan Knowles <alan@roojs.com>
Wed, 9 Jan 2019 10:06:12 +0000 (18:06 +0800)
12 files changed:
Roo/XComponent.js
Roo/bootstrap/Navbar.js
docs2/Roo.docs.SidebarNav.bjs
docs2/Roo.docs.SidebarNav.js
docs2/Roo.docs.bjs
docs2/Roo.docs.init.js
docs2/Roo.docs.js
docs2/index.html
roojs-bootstrap-debug.js
roojs-bootstrap.js
roojs-core-debug.js
roojs-core.js

index 7a18441..06dc502 100644 (file)
@@ -420,7 +420,7 @@ Roo.apply(Roo.XComponent, {
                 break;
             
             default:
-                if (obj.disabled) {
+                if (obj.disabled || obj.region == '#disabled') {
                         return;
                 }
                 break;
index 5903e45..f991efd 100644 (file)
@@ -109,7 +109,7 @@ Roo.extend(Roo.bootstrap.Navbar, Roo.bootstrap.Component,  {
     
     getChildContainer : function()
     {
-        if (this.el.select('.collapse').getCount()) {
+        if (this.el && this.el.select('.collapse').getCount()) {
             return this.el.select('.collapse',true).first();
         }
         
index 4113d0d..bd23bc7 100644 (file)
@@ -1,6 +1,6 @@
 {
  "name" : "Roo.docs.SidebarNav",
- "parent" : "",
+ "parent" : "#disabled",
  "title" : "",
  "path" : "/home/alan/gitlive/roojs1/docs2/Roo.docs.SidebarNav.bjs",
  "permname" : "",
@@ -12,7 +12,7 @@
  "items" : [
   {
    "listeners" : {
-    "render" : "function (_self)\n{\n    this.el.addClass(language);\n    \n}"
+    "render" : "function (_self)\n{\n  //  this.el.addClass(language);\n    \n}"
    },
    "String cls" : "left-menu-sidebar",
    "xtype" : "NavSidebar",
index eaa7fc4..fd03d81 100644 (file)
@@ -14,7 +14,7 @@ Roo.docs.SidebarNav = new Roo.XComponent({
   part     :  ["docs2", "SidebarNav" ],
   order    : '001-Roo.docs.SidebarNav',
   region   : 'center',
-  parent   : false,
+  parent   : '#disabled',
   name     : "unnamed module",
   disabled : false, 
   permname : '', 
@@ -28,7 +28,7 @@ Roo.docs.SidebarNav = new Roo.XComponent({
    listeners : {
     render : function (_self)
      {
-         this.el.addClass(language);
+       //  this.el.addClass(language);
          
      }
    },
index b239d13..8e7b0d5 100644 (file)
@@ -5,6 +5,9 @@
  "path" : "/home/alan/gitlive/roojs1/docs2/Roo.docs.bjs",
  "permname" : "",
  "modOrder" : "001",
+ "strings" : {
+  "098f6bcd4621d373cade4e832627b4f6" : "test"
+ },
  "items" : [
   {
    "listeners" : {
    "items" : [
     {
      "xtype" : "NavHeaderbar",
-     "* xinclude" : "Roo.doc.MobileSidebarMenu",
+     "* xinclude" : "Roo.docs.MobileSidebarMenu",
      "$ xns" : "Roo.bootstrap"
     },
     {
      "xtype" : "NavSidebar",
-     "* xinclude" : "Roo.doc.SidebarNav",
+     "* xinclude" : "Roo.docs.SidebarNav",
      "$ xns" : "Roo.bootstrap"
     },
     {
          "items" : [
           {
            "xtype" : "Header",
-           "$ String html" : "pagedata.page.title",
            "Number level" : 2,
-           "$ xns" : "Roo.bootstrap"
+           "$ xns" : "Roo.bootstrap",
+           "String html" : "test"
           },
           {
            "String tag" : "div",
            "xtype" : "Element",
-           "$ String html" : "pagedata.page.body",
-           "$ xns" : "Roo.bootstrap"
+           "$ xns" : "Roo.bootstrap",
+           "String html" : "test"
           }
          ]
         }
        ]
       }
      ]
-    },
-    {
-     "xtype" : "Container",
-     "* xinclude" : "Roo.docs.MobileFooter",
-     "$ xns" : "Roo.bootstrap"
     }
    ]
   }
index 2427f91..cffd24a 100644 (file)
@@ -16,15 +16,7 @@ Roo.docs.init = {
         
         Roo.XComponent.on('buildcomplete', function() {
             
-            var length = Roo.XComponent.modules.length;
-
-            if(
-                typeof(Roo.XComponent.modules[length - 1]) != 'undefined' 
-                && 
-                typeof(Roo.XComponent.modules[length - 1].el) != 'undefined'
-            ){
-                Roo.XComponent.modules[length - 1].el.fireEvent('render');
-            }
+            Roo.XComponent.modules[0].el.fireEvent('render');
             
         });
         
index 9dce771..d99d98d 100644 (file)
@@ -6,7 +6,9 @@ Roo.namespace('Roo');
 
 Roo.docs = new Roo.XComponent({
 
-
+ _strings : {
+  '098f6bcd4621d373cade4e832627b4f6' :"test"
+ },
 
   part     :  ["docs2", "docs" ],
   order    : '001-Roo.docs',
@@ -33,12 +35,12 @@ Roo.docs = new Roo.XComponent({
    xns : Roo.bootstrap,
    '|xns' : 'Roo.bootstrap',
    items  : [
-    Roo.apply(Roo.doc.MobileSidebarMenu._tree(), {
+    Roo.apply(Roo.docs.MobileSidebarMenu._tree(), {
      xtype : 'NavHeaderbar',
      xns : Roo.bootstrap,
      '|xns' : 'Roo.bootstrap'
     }),
-    Roo.apply(Roo.doc.SidebarNav._tree(), {
+    Roo.apply(Roo.docs.SidebarNav._tree(), {
      xtype : 'NavSidebar',
      xns : Roo.bootstrap,
      '|xns' : 'Roo.bootstrap'
@@ -64,14 +66,14 @@ Roo.docs = new Roo.XComponent({
          items  : [
           {
            xtype : 'Header',
-           html : pagedata.page.title,
+           html : _this._strings['098f6bcd4621d373cade4e832627b4f6'] /* test */,
            level : 2,
            xns : Roo.bootstrap,
            '|xns' : 'Roo.bootstrap'
           },
           {
            xtype : 'Element',
-           html : pagedata.page.body,
+           html : _this._strings['098f6bcd4621d373cade4e832627b4f6'] /* test */,
            tag : 'div',
            xns : Roo.bootstrap,
            '|xns' : 'Roo.bootstrap'
@@ -81,12 +83,7 @@ Roo.docs = new Roo.XComponent({
        ]
       }
      ]
-    },
-    Roo.apply(Roo.docs.MobileFooter._tree(), {
-     xtype : 'Container',
-     xns : Roo.bootstrap,
-     '|xns' : 'Roo.bootstrap'
-    })
+    }
    ]
   };  }
 });
index 0e2759a..39586ff 100644 (file)
         <meta property="og:image" content="http://www.roojs.org/images/roojs_logo.jpg" />        
         <meta property="og:site_name" content="Roojs" />
         
-        <link href="../css-bootstrap/bootstrap.min.css" rel="stylesheet" type="text/css"> 
-        
+        <link href="../css-bootstrap/bootstrap.min.css" rel="stylesheet" type="text/css">
+        <link href="../css-bootstrap/roojs-bootstrap.css" rel="stylesheet" type="text/css"> 
+
+        <link href="docs.css" rel="stylesheet" type="text/css">
+            
         
         
     </head>
@@ -38,8 +41,8 @@
     <script type="text/javascript" src="{rootURL}/roojs1/roojs-core-debug.js"></script>
     <script type="text/javascript" src="{rootURL}/roojs1/roojs-bootstrap-debug.js"></script>
  -->
-    <script type="text/javascript" src="/roojs1/roojs-core.js"></script>
-    <script type="text/javascript" src="/roojs1/roojs-bootstrap.js"></script>
+    <script type="text/javascript" src="/roojs1/roojs-core-debug.js"></script>
+    <script type="text/javascript" src="/roojs1/roojs-bootstrap-debug.js"></script>
  
  <!-- temp for testing 
     { outputJavascriptDir(#roojs1/Roo/bootstrap#,#MasonryBrick.js#,#LayoutMasonry.js#) }
index 3fc684a..40d7093 100644 (file)
@@ -3936,7 +3936,7 @@ Roo.extend(Roo.bootstrap.Navbar, Roo.bootstrap.Component,  {
     
     getChildContainer : function()
     {
-        if (this.el.select('.collapse').getCount()) {
+        if (this.el && this.el.select('.collapse').getCount()) {
             return this.el.select('.collapse',true).first();
         }
         
index b8a92f6..7b1ec0d 100644 (file)
@@ -156,7 +156,7 @@ Roo.bootstrap.Navbar=function(A){Roo.bootstrap.Navbar.superclass.constructor.cal
 ;},initEvents:function(){this.el.select('.navbar-toggle',true).on('click',function(){if(this.fireEvent('beforetoggle',this)!==false){var ce=this.el.select('.navbar-collapse',true).first();ce.toggleClass('in');if(ce.hasClass('collapse')){ce.removeClass('collapse');
 ce.addClass('show');var h=ce.getHeight();Roo.log(h);ce.removeClass('show');ce.addClass('collapsing');ce.setHeight(0);ce.on('transitionend',function(){Roo.log('done transition');ce.removeClass('collapsing');ce.addClass('show');ce.removeClass('collapse');ce.dom.style.height='';
 },this,{single:true});ce.setHeight(h);}else{ce.setHeight(ce.getHeight());ce.removeClass('show');ce.addClass('collapsing');ce.on('transitionend',function(){ce.dom.style.height='';ce.removeClass('collapsing');ce.addClass('collapse');},this,{single:true});ce.setHeight(0);
-}}},this);var A={tag:"div",cls:"x-dlg-mask"};this.maskEl=Roo.DomHelper.append(this.el,A,true);var B=this.el.getSize();this.maskEl.setSize(B.width,B.height);this.maskEl.enableDisplayMode("block");this.maskEl.hide();if(this.loadMask){this.maskEl.show();}},getChildContainer:function(){if(this.el.select('.collapse').getCount()){return this.el.select('.collapse',true).first();
+}}},this);var A={tag:"div",cls:"x-dlg-mask"};this.maskEl=Roo.DomHelper.append(this.el,A,true);var B=this.el.getSize();this.maskEl.setSize(B.width,B.height);this.maskEl.enableDisplayMode("block");this.maskEl.hide();if(this.loadMask){this.maskEl.show();}},getChildContainer:function(){if(this.el&&this.el.select('.collapse').getCount()){return this.el.select('.collapse',true).first();
 }return this.el;},mask:function(){this.maskEl.show();},unmask:function(){this.maskEl.hide();}});
 // Roo/bootstrap/NavSimplebar.js
 Roo.bootstrap.NavSimplebar=function(A){Roo.bootstrap.NavSimplebar.superclass.constructor.call(this,A);};Roo.extend(Roo.bootstrap.NavSimplebar,Roo.bootstrap.Navbar,{inverse:false,type:false,arrangement:'',align:false,weight:'light',main:false,tag:false,getAutoCreate:function(){var A={tag:this.tag||'div',cls:'navbar navbar-expand-lg roo-navbar-simple'}
index a61b053..6f7d6c8 100644 (file)
@@ -16418,7 +16418,7 @@ Roo.apply(Roo.XComponent, {
                 break;
             
             default:
-                if (obj.disabled) {
+                if (obj.disabled || obj.region == '#disabled') {
                         return;
                 }
                 break;
index 601bef1..0948a1a 100644 (file)
@@ -665,10 +665,10 @@ if(!this.parent&&C){this.parent={el:true};}if(!this.parent){Roo.debug&&Roo.log("
 })};}else{this.parent={el:new Roo.BorderLayout(el||document.body,{center:{titlebar:false,autoScroll:false,closeOnTab:true,tabPosition:'top',alwaysShowTabs:el&&hp?false:true,hideTabs:el||!hp?true:false,minTabWidth:140}})};}}if(!this.parent.el){return;}A.region=A.region||this.region;
 var D=false;if(this.parent.el===true){if(el){A.el=el;}this.parent.el=Roo.factory(A);D=true;}this.el=this.parent.el.addxtype(A,undefined,D);this.fireEvent('built',this);this.panel=this.el;this.layout=this.panel.layout;this.parentLayout=this.parent.layout||false;
 }});Roo.apply(Roo.XComponent,{hideProgress:false,buildCompleted:false,topModule:false,modules:[],elmodules:[],is_alt:false,build_from_html:false,register:function(A){Roo.XComponent.event.fireEvent('register',A);switch(typeof(A.disabled)){case 'undefined':break;
-case 'function':if(A.disabled()){return;}break;default:if(A.disabled){return;}break;}this.modules.push(A);},toObject:function(str){if(!str||typeof(str)=='object'){return str;}if(str.substring(0,1)=='#'){return str;}var ar=str.split('.');var rt,o;rt=ar.shift();
-try{eval('if (typeof '+rt+' == "undefined"){ o = false;} o = '+rt+';');}catch(e){throw "Module not found : "+str;}if(o===false){throw "Module not found : "+str;}Roo.each(ar,function(e){if(typeof(o[e])=='undefined'){throw "Module not found : "+str;}o=o[e];
-});return o;},preBuild:function(){var _t=this;Roo.each(this.modules,function(A){Roo.XComponent.event.fireEvent('beforebuild',A);var B=A.parent;try{A.parent=this.toObject(B);}catch(e){Roo.debug&&Roo.log("parent:toObject failed: "+e.toString());return;}if(!A.parent){Roo.debug&&Roo.log("GOT top level module");
-Roo.debug&&Roo.log(A);A.modules=new Roo.util.MixedCollection(false,function(o){return o.order+''});this.topModule=A;return;}if(typeof(A.parent)=='string'){this.elmodules.push(A);return;}if(A.parent.constructor!=Roo.XComponent){Roo.debug&&Roo.log("Warning : Object Parent is not instance of XComponent:"+A.name)}
+case 'function':if(A.disabled()){return;}break;default:if(A.disabled||A.region=='#disabled'){return;}break;}this.modules.push(A);},toObject:function(str){if(!str||typeof(str)=='object'){return str;}if(str.substring(0,1)=='#'){return str;}var ar=str.split('.');
+var rt,o;rt=ar.shift();try{eval('if (typeof '+rt+' == "undefined"){ o = false;} o = '+rt+';');}catch(e){throw "Module not found : "+str;}if(o===false){throw "Module not found : "+str;}Roo.each(ar,function(e){if(typeof(o[e])=='undefined'){throw "Module not found : "+str;
+}o=o[e];});return o;},preBuild:function(){var _t=this;Roo.each(this.modules,function(A){Roo.XComponent.event.fireEvent('beforebuild',A);var B=A.parent;try{A.parent=this.toObject(B);}catch(e){Roo.debug&&Roo.log("parent:toObject failed: "+e.toString());return;
+}if(!A.parent){Roo.debug&&Roo.log("GOT top level module");Roo.debug&&Roo.log(A);A.modules=new Roo.util.MixedCollection(false,function(o){return o.order+''});this.topModule=A;return;}if(typeof(A.parent)=='string'){this.elmodules.push(A);return;}if(A.parent.constructor!=Roo.XComponent){Roo.debug&&Roo.log("Warning : Object Parent is not instance of XComponent:"+A.name)}
 if(!A.parent.modules){A.parent.modules=new Roo.util.MixedCollection(false,function(o){return o.order+''});}if(A.parent.disabled){A.disabled=true;}A.parent.modules.add(A);},this);},buildOrder:function(){var A=this;var B=function(a,b){return String(a).toUpperCase()>String(b).toUpperCase()?1:-1;
 };if((!this.topModule||!this.topModule.modules)&&!this.elmodules.length){throw "No top level modules to build";}var C=this.topModule?[this.topModule]:[];Roo.each(this.elmodules,function(e){C.push(e);if(!this.topModule&&typeof(e.parent)=='string'&&e.parent.substring(0,1)=='#'&&Roo.get(e.parent.substr(1))){A.topModule=e;
 }});var D=function(m){Roo.debug&&Roo.log("build Order: add: "+m.name);C.push(m);if(m.modules&&!m.disabled){Roo.debug&&Roo.log("build Order: "+m.modules.length+" child modules");m.modules.keySort('ASC',B);Roo.debug&&Roo.log("build Order: "+m.modules.length+" child modules (after sort)");