![]() |
The Java Developers Almanac 1.4 |
|
e771. Determining If a JRadioButton Component Is Selected // This method returns true if btn is selected; false otherwise
public static boolean isSelected(JRadioButton btn) {
DefaultButtonModel model = (DefaultButtonModel)btn.getModel();
return model.getGroup().isSelected(model);
}
e769. Selecting a JRadioButton Component in a Button Group e770. Determining the Selected JRadioButton in a Button Group e772. Adding an Icon to the Label of a JRadioButton Component e773. Customizing the Icons in a JRadioButton Component © 2002 Addison-Wesley. |