When I discovered the different API for manipulating different controls, I was quite surprised.
Using the auto completion in NB, I expected to find a setOnAction() method on each "ButtonBase" controls such as Button.
I now understand that, in some case we have to use the setOnAction() (Button or HyperLink) and have to use the selectedProperty for others.
For the JavaFX adoption, I would like to have more common strategy for most of controls.
Moreover, when I design a new GUI, I often use Buttons, and sometimes I switch the controls to CheckBox etc..., and in that case it no more compiles.
Maybe I missed a "core design" of the JFX Controls, but from a beginner perspective, I think my point makes sense.
Thanks for your attention!
Using the auto completion in NB, I expected to find a setOnAction() method on each "ButtonBase" controls such as Button.
I now understand that, in some case we have to use the setOnAction() (Button or HyperLink) and have to use the selectedProperty for others.
For the JavaFX adoption, I would like to have more common strategy for most of controls.
Moreover, when I design a new GUI, I often use Buttons, and sometimes I switch the controls to CheckBox etc..., and in that case it no more compiles.
Maybe I missed a "core design" of the JFX Controls, but from a beginner perspective, I think my point makes sense.
Thanks for your attention!