use of org.uberfire.ext.widgets.common.client.common.AbstractRestrictedEntryTextBox in project drools-wb by kiegroup.
the class DTCellValueWidgetFactory method makeNumericByteTextBox.
private AbstractRestrictedEntryTextBox makeNumericByteTextBox(final DTCellValue52 value) {
final AbstractRestrictedEntryTextBox tb = new NumericByteTextBox(allowEmptyValues);
final Byte numericValue = (Byte) value.getNumericValue();
tb.setValue(numericValue == null ? "" : numericValue.toString());
// Wire up update handler
tb.setEnabled(!isReadOnly);
addNumericTextBoxChangeHandler(tb, value, (input -> Byte.valueOf(input)), (Byte) null, new Byte("0"));
return tb;
}
use of org.uberfire.ext.widgets.common.client.common.AbstractRestrictedEntryTextBox in project drools-wb by kiegroup.
the class DTCellValueWidgetFactory method makeNumericIntegerTextBox.
private AbstractRestrictedEntryTextBox makeNumericIntegerTextBox(final DTCellValue52 value) {
final AbstractRestrictedEntryTextBox tb = new NumericIntegerTextBox(allowEmptyValues);
final Integer numericValue = (Integer) value.getNumericValue();
tb.setValue(numericValue == null ? "" : numericValue.toString());
// Wire up update handler
tb.setEnabled(!isReadOnly);
addNumericTextBoxChangeHandler(tb, value, (input -> Integer.valueOf(input)), (Integer) null, 0);
return tb;
}
use of org.uberfire.ext.widgets.common.client.common.AbstractRestrictedEntryTextBox in project drools-wb by kiegroup.
the class DTCellValueWidgetFactory method makeNumericFloatTextBox.
private AbstractRestrictedEntryTextBox makeNumericFloatTextBox(final DTCellValue52 value) {
final AbstractRestrictedEntryTextBox tb = new NumericFloatTextBox(allowEmptyValues);
final Float numericValue = (Float) value.getNumericValue();
tb.setValue(numericValue == null ? "" : numericValue.toString());
// Wire up update handler
tb.setEnabled(!isReadOnly);
addNumericTextBoxChangeHandler(tb, value, (input -> Float.valueOf(input)), (Float) null, new Float("0"));
return tb;
}
use of org.uberfire.ext.widgets.common.client.common.AbstractRestrictedEntryTextBox in project drools-wb by kiegroup.
the class DTCellValueWidgetFactory method makeNumericDoubleTextBox.
private AbstractRestrictedEntryTextBox makeNumericDoubleTextBox(final DTCellValue52 value) {
final AbstractRestrictedEntryTextBox tb = new NumericDoubleTextBox(allowEmptyValues);
final Double numericValue = (Double) value.getNumericValue();
tb.setValue(numericValue == null ? "" : numericValue.toString());
// Wire up update handler
tb.setEnabled(!isReadOnly);
addNumericTextBoxChangeHandler(tb, value, (input -> Double.valueOf(input)), (Double) null, new Double("0"));
return tb;
}
use of org.uberfire.ext.widgets.common.client.common.AbstractRestrictedEntryTextBox in project drools-wb by kiegroup.
the class DTCellValueWidgetFactory method makeNumericBigIntegerTextBox.
private AbstractRestrictedEntryTextBox makeNumericBigIntegerTextBox(final DTCellValue52 value) {
final AbstractRestrictedEntryTextBox tb = new NumericBigIntegerTextBox(allowEmptyValues);
final BigInteger numericValue = (BigInteger) value.getNumericValue();
tb.setValue(numericValue == null ? "" : numericValue.toString());
// Wire up update handler
tb.setEnabled(!isReadOnly);
addNumericTextBoxChangeHandler(tb, value, (input -> new BigInteger(input)), (BigInteger) null, BigInteger.ZERO);
return tb;
}
Aggregations