Add field_number to Block Factory.

This commit is contained in:
Neil Fraser
2016-07-10 22:54:57 -07:00
parent e1ad58f2e9
commit efc2ca3d82
4 changed files with 74 additions and 2 deletions

View File

@@ -44,6 +44,7 @@ goog.require('goog.math');
*/
Blockly.FieldNumber =
function(value, opt_min, opt_max, opt_precision, opt_validator) {
value = String(value);
Blockly.FieldNumber.superClass_.constructor.call(this, value, opt_validator);
this.setConstraints(opt_min, opt_max, opt_precision);
};