roojs-bootstrap.js
authorAlan Knowles <alan@roojs.com>
Fri, 16 Oct 2015 02:36:45 +0000 (10:36 +0800)
committerAlan Knowles <alan@roojs.com>
Fri, 16 Oct 2015 02:36:45 +0000 (10:36 +0800)
roojs-bootstrap-debug.js

roojs-bootstrap-debug.js
roojs-bootstrap.js

index f8ca6ff..f1a6d1d 100644 (file)
@@ -1369,9 +1369,11 @@ Roo.extend(Roo.bootstrap.Header, Roo.bootstrap.Component,  {
     
     getAutoCreate : function(){
         
+        
+        
         var cfg = {
             tag: 'h' + (1 *this.level),
-            html: this.html || 'fill in html'
+            html: this.html || (this.cn ? '' : 'fill in html')
         } ;
         
         return cfg;
@@ -2148,13 +2150,15 @@ Roo.extend(Roo.bootstrap.Modal, Roo.bootstrap.Component,  {
         if(this.tabIndex !== undefined){
             this.el.dom.setAttribute('tabIndex', this.tabIndex);
         }
+        
+        
         this.bodyEl = this.el.select('.modal-body',true).first();
         this.closeEl = this.el.select('.modal-header .close', true).first();
         this.footerEl = this.el.select('.modal-footer',true).first();
         this.titleEl = this.el.select('.modal-title',true).first();
         
         
-        
+         
         this.maskEl = Roo.DomHelper.append(document.body, {tag: "div", cls:"x-dlg-mask"}, true);
         this.maskEl.enableDisplayMode("block");
         this.maskEl.hide();
index 6876211..9fab46f 100644 (file)
@@ -36,7 +36,7 @@ A.html=this.html||A.html;A.src=this.src||A.src;if(['rounded','circle','thumbnail
 Roo.bootstrap.Link=function(A){Roo.bootstrap.Link.superclass.constructor.call(this,A);this.addEvents({"click":true});};Roo.extend(Roo.bootstrap.Link,Roo.bootstrap.Component,{href:false,target:false,preventDefault:false,anchor:false,alt:false,getAutoCreate:function(){var A={tag:'a'};if(this.anchor===false){A.html=this.html||'html-missing';A.href=this.href||'#';}else {A.name=this.anchor;if(this.html!==false){A.html=this.html;}if(this.href!==false){A.href=this.href;}}if(this.alt!==false){A.alt=this.alt;}if(this.target!==false){A.target=this.target;}return A;},initEvents:function(){if(!this.href||this.preventDefault){this.el.on('click',this.onClick,this);}},onClick:function(e){if(this.preventDefault){e.preventDefault();}
 this.fireEvent('click',this,e);}});
 //Roo/bootstrap/Header.js
-Roo.bootstrap.Header=function(A){Roo.bootstrap.Header.superclass.constructor.call(this,A);};Roo.extend(Roo.bootstrap.Header,Roo.bootstrap.Component,{html:false,level:1,getAutoCreate:function(){var A={tag:'h'+(1*this.level),html:this.html||'fill in html'};return A;}});
+Roo.bootstrap.Header=function(A){Roo.bootstrap.Header.superclass.constructor.call(this,A);};Roo.extend(Roo.bootstrap.Header,Roo.bootstrap.Component,{html:false,level:1,getAutoCreate:function(){var A={tag:'h'+(1*this.level),html:this.html||(this.cn?'':'fill in html')};return A;}});
 //Roo/bootstrap/MenuMgr.js
 Roo.bootstrap.MenuMgr=function(){var A,B,C={},D=false,E=new Date();function init(){A={};B=new Roo.util.MixedCollection();Roo.get(document).addKeyListener(27,function(){if(B.length>0){hideAll();}});}function hideAll(){if(B&&B.length>0){var c=B.clone();c.each(function(m){m.hide();});}}function onHide(m){B.remove(m);if(B.length<1){Roo.get(document).un("mouseup",onMouseDown);D=false;}}function onShow(m){var F=B.last();E=new Date();B.add(m);if(!D){Roo.get(document).on("mouseup",onMouseDown);D=true;}if(m.parentMenu){m.parentMenu.activeChild=m;}else if(F&&F.isVisible()){}}function onBeforeHide(m){if(m.activeChild){m.activeChild.hide();}if(m.autoHideTimer){clearTimeout(m.autoHideTimer);delete m.autoHideTimer;}}function onBeforeShow(m){var pm=m.parentMenu;if(!pm&&!m.allowOtherMenus){hideAll();}else if(pm&&pm.activeChild&&B!=m){pm.activeChild.hide();}}function onMouseDown(e){Roo.log("on MouseDown");if(E.getElapsed()>50&&B.length>0&&!e.getTarget(".x-menu")&&!e.getTarget('.user-menu')){hideAll();}}function onBeforeCheck(mi,F){if(F){var g=C[mi.group];for(var i=0,l=g.length;i<l;i++){if(g[i]!=mi){g[i].setChecked(false);}}}}return {hideAll:function(){hideAll();},register:function(F){if(!A){init();}
 A[F.id]=F;F.on("beforehide",onBeforeHide);F.on("hide",onHide);F.on("beforeshow",onBeforeShow);F.on("show",onShow);var g=F.group;if(g&&F.events["checkchange"]){if(!C[g]){C[g]=[];}