jfxtras-labs
jfxtras-labs copied to clipboard
BigDecimalField focus problem
BigDecimalField focus have a problem that can be demonstrated as follow:
- Create a window containing at least 2 BigDecimalField controls.
- Click in the first BigDecimalField to give it focus.
- Make the window lose focus (click for example on the desktop).
- Click in the second BigDecimalField to give it focus (do not give focus to the window first).
- The focus will alternate indefinitely between the 2 BigDecimalField controls.
Here is a small program to execute: import javafx.application.Application; import javafx.scene.Scene; import javafx.scene.layout.VBox; import javafx.stage.Stage; import jfxtras.labs.scene.control.BigDecimalField;
public class BigDecimalFieldFocusBugDemo extends Application {
public static void main(String[] args) {
launch(args);
}
@Override
public void start(Stage primaryStage) {
primaryStage.setTitle("Big Decimal Field Focus Bug Demo");
primaryStage.setScene(new Scene(createControls()));
primaryStage.show();
}
private VBox createControls() {
return new VBox(new BigDecimalField(), new BigDecimalField());
}
}
I would like to point out that jfxtras-labs is a playground where developers can drop whatever experiment they are doing, in whatever state their code is. It only should not break the build. Usage of labs is at your own risk. So I'm not sure if the original developer is still supporting his code.