roojs-ui.js
authoredward <edward@roojs.com>
Mon, 18 Jul 2016 06:06:19 +0000 (14:06 +0800)
committeredward <edward@roojs.com>
Mon, 18 Jul 2016 06:06:19 +0000 (14:06 +0800)
roojs-ui-debug.js
roojs-all.js
roojs-debug.js

roojs-all.js
roojs-debug.js
roojs-ui-debug.js
roojs-ui.js

index 1344072..3caa459 100644 (file)
@@ -1685,7 +1685,7 @@ if(!this.boxLabel){this.el.alignTo(this.wrap,'c-c');}},initEvents:function(){Roo
 this.el.on('DOMAttrModified',this.setFromHidden,this);this.el.on('propertychange',this.setFromHidden,this);if(this.boxLabel){this.wrap.createChild({tag:'label',htmlFor:this.el.id,cls:'x-form-cb-label',html:this.boxLabel});}this.setChecked(this.checked);},initValue:Roo.emptyFn,getValue:function(){if(this.el){return String(this.el.dom.value)==String(this.inputValue)?this.inputValue:this.valueOff;
 }return this.valueOff;},onClick:function(){if(this.disabled){return;}this.setChecked(!this.checked);},setValue:function(v,A){this.setChecked(String(v)===String(this.inputValue),A);},setChecked:function(A,B){if(this.inSetChecked){this.checked=A;return;}if(this.wrap){this.wrap[A?'addClass':'removeClass']('x-menu-item-checked');
 }this.checked=A;if(B!==true){this.fireEvent('check',this,A);}this.inSetChecked=true;this.el.dom.value=A?this.inputValue:this.valueOff;this.inSetChecked=false;},setFromHidden:function(){if(!this.el){return;}this.setValue(this.el.dom.value);},onDestroy:function(){if(this.viewEl){Roo.get(this.viewEl).remove();
-}Roo.form.Checkbox.superclass.onDestroy.call(this);}});
+}Roo.form.Checkbox.superclass.onDestroy.call(this);},setBoxLabel:function(A){this.wrap.select('.x-form-cb-label',true).first().dom.innerHTML=A;}});
 // Roo/form/Radio.js
 Roo.form.Radio=function(){Roo.form.Radio.superclass.constructor.apply(this,arguments);};Roo.extend(Roo.form.Radio,Roo.form.Checkbox,{inputType:'radio',getGroupValue:function(){return this.el.up('form').child('input[name='+this.el.dom.name+']:checked',true).value;
 },onRender:function(ct,A){Roo.form.Checkbox.superclass.onRender.call(this,ct,A);if(this.inputValue!==undefined){this.el.dom.value=this.inputValue;}this.wrap=this.el.wrap({cls:"x-form-check-wrap"});if(this.boxLabel){this.wrap.createChild({tag:'label',htmlFor:this.el.id,cls:'x-form-cb-label',html:this.boxLabel}
index 635f468..0a1f03f 100644 (file)
@@ -41110,6 +41110,11 @@ Roo.extend(Roo.form.Checkbox, Roo.form.Field,  {
         }
          
         Roo.form.Checkbox.superclass.onDestroy.call(this);
+    },
+    
+    setBoxLabel : function(str)
+    {
+        this.wrap.select('.x-form-cb-label', true).first().dom.innerHTML = str;
     }
 
 });/*
index 91e1514..89dc69d 100644 (file)
@@ -24637,6 +24637,11 @@ Roo.extend(Roo.form.Checkbox, Roo.form.Field,  {
         }
          
         Roo.form.Checkbox.superclass.onDestroy.call(this);
+    },
+    
+    setBoxLabel : function(str)
+    {
+        this.wrap.select('.x-form-cb-label', true).first().dom.innerHTML = str;
     }
 
 });/*
index 7f28c61..6c70b1e 100644 (file)
@@ -1015,7 +1015,7 @@ if(!this.boxLabel){this.el.alignTo(this.wrap,'c-c');}},initEvents:function(){Roo
 this.el.on('DOMAttrModified',this.setFromHidden,this);this.el.on('propertychange',this.setFromHidden,this);if(this.boxLabel){this.wrap.createChild({tag:'label',htmlFor:this.el.id,cls:'x-form-cb-label',html:this.boxLabel});}this.setChecked(this.checked);},initValue:Roo.emptyFn,getValue:function(){if(this.el){return String(this.el.dom.value)==String(this.inputValue)?this.inputValue:this.valueOff;
 }return this.valueOff;},onClick:function(){if(this.disabled){return;}this.setChecked(!this.checked);},setValue:function(v,A){this.setChecked(String(v)===String(this.inputValue),A);},setChecked:function(A,B){if(this.inSetChecked){this.checked=A;return;}if(this.wrap){this.wrap[A?'addClass':'removeClass']('x-menu-item-checked');
 }this.checked=A;if(B!==true){this.fireEvent('check',this,A);}this.inSetChecked=true;this.el.dom.value=A?this.inputValue:this.valueOff;this.inSetChecked=false;},setFromHidden:function(){if(!this.el){return;}this.setValue(this.el.dom.value);},onDestroy:function(){if(this.viewEl){Roo.get(this.viewEl).remove();
-}Roo.form.Checkbox.superclass.onDestroy.call(this);}});
+}Roo.form.Checkbox.superclass.onDestroy.call(this);},setBoxLabel:function(A){this.wrap.select('.x-form-cb-label',true).first().dom.innerHTML=A;}});
 // Roo/form/Radio.js
 Roo.form.Radio=function(){Roo.form.Radio.superclass.constructor.apply(this,arguments);};Roo.extend(Roo.form.Radio,Roo.form.Checkbox,{inputType:'radio',getGroupValue:function(){return this.el.up('form').child('input[name='+this.el.dom.name+']:checked',true).value;
 },onRender:function(ct,A){Roo.form.Checkbox.superclass.onRender.call(this,ct,A);if(this.inputValue!==undefined){this.el.dom.value=this.inputValue;}this.wrap=this.el.wrap({cls:"x-form-check-wrap"});if(this.boxLabel){this.wrap.createChild({tag:'label',htmlFor:this.el.id,cls:'x-form-cb-label',html:this.boxLabel}