PDA

View Full Version : validationDelay is OBE



bruce1058
24 Jul 2012, 7:16 AM
The config item validationDelay is not carried forward from 3.x to 4.x for form Text fields. Is there a replacement config item or is validationDelay implemented in a new way? If so what is it?

Daniil
3 Dec 2012, 11:39 PM
Hi @bruce1058,

The checkChangeBuffer option appears what you need.
http://docs.sencha.com/ext-js/4-1/#!/api/Ext.form.field.Base-cfg-checkChangeBuffer

You can be also interested in the checkChangeEvents option.
http://docs.sencha.com/ext-js/4-1/#!/api/Ext.form.field.Base-cfg-checkChangeEvents

bruce1058
4 Dec 2012, 7:48 AM
Thanks Daniil, That works great

We were using a DelayedTask on the TextField validator as a solution.

var filter_tf = Ext.create('Ext.form.TextField',{
...
validationTask: new Ext.util.DelayedTask(function(txt){
...
}),
validator: function(text){
this.validationTask.delay(500, null, null, [text]);
return true;
}
});

Daniil
4 Dec 2012, 8:33 AM
Glad to help.

By the way, there is a special [CODE] tag (# option in the editor's toolbar). It formats code, so, it looks good.