use of org.uberfire.ext.widgets.common.client.common.NumericTextBox in project drools-wb by kiegroup.
the class DTCellValueWidgetFactory method makeNumericTextBox.
private AbstractRestrictedEntryTextBox makeNumericTextBox(final DTCellValue52 value) {
final AbstractRestrictedEntryTextBox tb = new NumericTextBox(allowEmptyValues);
final BigDecimal numericValue = (BigDecimal) value.getNumericValue();
tb.setValue(numericValue == null ? "" : numericValue.toPlainString());
// Wire up update handler
tb.setEnabled(!isReadOnly);
addNumericTextBoxChangeHandler(tb, value, (input -> new BigDecimal(input)), (BigDecimal) null, BigDecimal.ZERO);
return tb;
}
Aggregations