Skip to content

Commit 0863e28

Browse files
committed
Table: add disabled icon for boolean renderer (issue #1008)
1 parent 4945378 commit 0863e28

1 file changed

Lines changed: 5 additions & 2 deletions

File tree

flatlaf-core/src/main/java/com/formdev/flatlaf/ui/FlatTableUI.java

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,7 @@
3939
import java.util.Map;
4040
import javax.swing.Action;
4141
import javax.swing.ActionMap;
42+
import javax.swing.Icon;
4243
import javax.swing.JComponent;
4344
import javax.swing.JScrollPane;
4445
import javax.swing.JTable;
@@ -989,12 +990,14 @@ private static class FlatBooleanRenderer
989990

990991
FlatBooleanRenderer() {
991992
setHorizontalAlignment( SwingConstants.CENTER );
992-
setIcon( new FlatCheckBoxIcon() {
993+
Icon icon = new FlatCheckBoxIcon() {
993994
@Override
994995
protected boolean isSelected( Component c ) {
995996
return selected;
996997
}
997-
} );
998+
};
999+
setIcon( icon );
1000+
setDisabledIcon( icon );
9981001
}
9991002

10001003
@Override

0 commit comments

Comments
 (0)