Search in sources :

Example 1 with SimpleFloatProperty

use of javafx.beans.property.SimpleFloatProperty in project dolphin-platform by canoo.

the class FXWrapper method wrapFloatProperty.

/**
 * Create a JavaFX {@link javafx.beans.property.FloatProperty} as a wrapper for a dolphin platform property
 *
 * @param dolphinProperty the dolphin platform property
 * @return the JavaFX property
 */
public static FloatProperty wrapFloatProperty(final Property<Float> dolphinProperty) {
    Assert.requireNonNull(dolphinProperty, "dolphinProperty");
    final FloatProperty property = new SimpleFloatProperty();
    FXBinder.bind(property).bidirectionalToNumeric(dolphinProperty);
    return property;
}
Also used : SimpleFloatProperty(javafx.beans.property.SimpleFloatProperty) SimpleFloatProperty(javafx.beans.property.SimpleFloatProperty) FloatProperty(javafx.beans.property.FloatProperty)

Aggregations

FloatProperty (javafx.beans.property.FloatProperty)1 SimpleFloatProperty (javafx.beans.property.SimpleFloatProperty)1