[CHG] select all field content when focusing integer or float field
bzr revid: xmo@openerp.com-20120808154126-wy9b96px9fasmu7e
This commit is contained in:
parent
163b211e12
commit
065ffcd244
|
@ -2085,7 +2085,7 @@ instance.web.form.FieldChar = instance.web.form.AbstractField.extend(instance.we
|
||||||
return this.get('value') === '' || this._super();
|
return this.get('value') === '' || this._super();
|
||||||
},
|
},
|
||||||
focus: function() {
|
focus: function() {
|
||||||
this.$element.find('input:first').focus();
|
this.$('input:first').focus();
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
@ -2169,6 +2169,9 @@ instance.web.form.FieldFloat = instance.web.form.FieldChar.extend({
|
||||||
value_ = 0;
|
value_ = 0;
|
||||||
}
|
}
|
||||||
this._super.apply(this, [value_]);
|
this._super.apply(this, [value_]);
|
||||||
|
},
|
||||||
|
focus: function () {
|
||||||
|
this.$('input:first').select();
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue