modules/controls/src/main/java/com/sun/javafx/scene/control/skin/RadioButtonSkin.java
Print this page
*** 23,38 ****
* questions.
*/
package com.sun.javafx.scene.control.skin;
import javafx.scene.control.RadioButton;
import javafx.scene.layout.StackPane;
import com.sun.javafx.scene.control.behavior.ButtonBehavior;
! public class RadioButtonSkin extends LabeledSkinBase<RadioButton, ButtonBehavior<RadioButton>> {
/** The radio contains the "dot", which is usually a circle */
private StackPane radio;
/**
--- 23,39 ----
* questions.
*/
package com.sun.javafx.scene.control.skin;
+ import com.sun.javafx.scene.control.behavior.ToggleButtonBehavior;
import javafx.scene.control.RadioButton;
import javafx.scene.layout.StackPane;
import com.sun.javafx.scene.control.behavior.ButtonBehavior;
! public class RadioButtonSkin extends LabeledSkinBase<RadioButton, ToggleButtonBehavior<RadioButton>> {
/** The radio contains the "dot", which is usually a circle */
private StackPane radio;
/**
*** 41,51 ****
* NOTE: This extra node should be eliminated in the future.
* Instead, position inner nodes directly with the utility
* functions in Pane (computeXOffset()/computeYOffset()).
*/
public RadioButtonSkin(RadioButton radioButton) {
! super(radioButton, new ButtonBehavior<RadioButton>(radioButton));
radio = createRadio();
updateChildren();
}
--- 42,52 ----
* NOTE: This extra node should be eliminated in the future.
* Instead, position inner nodes directly with the utility
* functions in Pane (computeXOffset()/computeYOffset()).
*/
public RadioButtonSkin(RadioButton radioButton) {
! super(radioButton, new ToggleButtonBehavior<>(radioButton));
radio = createRadio();
updateChildren();
}