},
select: function () {
- Roo.log("SELECT CALLED");
+ //Roo.log("SELECT CALLED");
},
selectByValue : function(xv, scrollIntoView){
onSelect : function(record, index){
- Roo.log("onselect Called");
+ // Roo.log("onselect Called");
// this is only called by the clear button now..
- this.view.clearSelections();
+ this.view.clearSelections();
+ this.setValue('[]');
+ if (this.value != this.valueBefore) {
+ this.fireEvent('change', this, this.value, this.valueBefore);
+ this.valueBefore = this.value;
+ }
},
getValueArray : function()
{
var ar = [] ;
try {
- Roo.log(this.value);
+ //Roo.log(this.value);
+ if (typeof(this.value) == 'undefined') {
+ return [];
+ }
var ar = Roo.decode(this.value);
return ar instanceof Array ? ar : []; //?? valid?
},
expand : function ()
{
+
Roo.form.ComboCheck.superclass.expand.call(this);
- this.valueBefore = this.value;
+ this.valueBefore = typeof(this.value) == 'undefined' ? '' : this.value;
+ //this.valueBefore = typeof(this.valueBefore) == 'undefined' ? '' : this.valueBefore;
},
r = st.getAt(i);
nv.push(r.get(this.valueField));
},this);
- this.setValue(Roo.encode(nv))
+ this.setValue(Roo.encode(nv));
if (this.value != this.valueBefore) {
this.fireEvent('change', this, this.value, this.valueBefore);
+ this.valueBefore = this.value;
}
},