diff options
author | David Gilbert <david.gilbert@object-refinery.com> | 2006-09-26 10:49:50 +0000 |
---|---|---|
committer | David Gilbert <david.gilbert@object-refinery.com> | 2006-09-26 10:49:50 +0000 |
commit | 016aec72853b207b4bd06667677e22b362a75810 (patch) | |
tree | abf8aca162adac080cd2d9b7356219296b4dfb46 /javax/swing/plaf | |
parent | 531e39762343dc00a415b75c19443bf724daac94 (diff) | |
download | classpath-016aec72853b207b4bd06667677e22b362a75810.tar.gz |
2006-09-26 David Gilbert <david.gilbert@object-refinery.com>
* javax/swing/plaf/metal/MetalIconFactory.java
(FileIcon16.paintIcon): Fetch colors from look and feel,
(FolderIcon16.paintIcon): Likewise.
Diffstat (limited to 'javax/swing/plaf')
-rw-r--r-- | javax/swing/plaf/metal/MetalIconFactory.java | 15 |
1 files changed, 6 insertions, 9 deletions
diff --git a/javax/swing/plaf/metal/MetalIconFactory.java b/javax/swing/plaf/metal/MetalIconFactory.java index 16ad9aeb2..5cd41b266 100644 --- a/javax/swing/plaf/metal/MetalIconFactory.java +++ b/javax/swing/plaf/metal/MetalIconFactory.java @@ -54,7 +54,6 @@ import javax.swing.JRadioButtonMenuItem; import javax.swing.JSlider; import javax.swing.SwingConstants; import javax.swing.UIManager; -import javax.swing.plaf.IconUIResource; import javax.swing.plaf.UIResource; @@ -569,8 +568,7 @@ public class MetalIconFactory implements Serializable */ public void paintIcon(Component c, Graphics g, int x, int y) { - // TODO: pick up appropriate UI colors - g.setColor(Color.black); + g.setColor(MetalLookAndFeel.getBlack()); g.drawLine(x, y, x + 9, y); g.drawLine(x, y + 1, x, y + 15); g.drawLine(x, y + 15, x + 12, y + 15); @@ -580,7 +578,7 @@ public class MetalIconFactory implements Serializable g.drawLine(x + 7, y + 2, x + 11, y + 6); g.drawLine(x + 8, y + 1, x + 9, y + 1); - g.setColor(new Color(204, 204, 255)); + g.setColor(MetalLookAndFeel.getPrimaryControl()); g.drawLine(x + 1, y + 1, x + 7, y + 1); g.drawLine(x + 1, y + 1, x + 1, y + 14); g.drawLine(x + 1, y + 14, x + 11, y + 14); @@ -649,19 +647,18 @@ public class MetalIconFactory implements Serializable */ public void paintIcon(Component c, Graphics g, int x, int y) { - // TODO: pick up appropriate UI colors - g.setColor(Color.black); + g.setColor(MetalLookAndFeel.getBlack()); g.drawLine(x, y + 3, x, y + 12); g.drawLine(x, y + 12, x + 15, y + 12); g.drawLine(x + 15, y + 12, x + 15, y + 2); g.drawLine(x + 14, y + 3, x + 9, y + 3); g.drawLine(x + 8, y + 2, x + 1, y + 2); - g.setColor(new Color(204, 204, 255)); + g.setColor(MetalLookAndFeel.getPrimaryControl()); g.fillRect(x + 2, y + 4, 7, 8); g.fillRect(x + 9, y + 5, 6, 7); - g.setColor(new Color(102, 102, 153)); + g.setColor(MetalLookAndFeel.getPrimaryControlShadow()); g.drawLine(x + 9, y + 2, x + 14, y + 2); - g.setColor(new Color(50, 50, 120)); + g.setColor(MetalLookAndFeel.getPrimaryControlDarkShadow()); g.drawLine(x + 9, y + 1, x + 15, y + 1); g.drawLine(x + 10, y, x + 15, y); } |