下面列出了javax.swing.JRadioButton#getDisabledIcon ( ) 实例代码,或者点击链接到github查看源代码,也可以在右侧发表评论。
private static Icon getDisabledIconSafe(JRadioButton radio) {
Icon icon = radio.getIcon();
if (icon == null) {
return getDefaultIcon();
}
Icon disabledIcon = radio.getDisabledIcon();
return (disabledIcon != null) ? disabledIcon : getIconSafe(radio);
}
private static Icon getDisabledIconSafe(JRadioButton radio) {
Icon icon = radio.getIcon();
if (icon == null) {
return getDefaultIcon();
}
Icon disabledIcon = radio.getDisabledIcon();
return (disabledIcon != null) ? disabledIcon : getIconSafe(radio);
}