Exemplo n.º 1
0
 public void paintBackground(Graphics g, JComponent c) {
   if (c.isOpaque()) {
     Component parent = c.getParent();
     if ((parent != null) && (parent.getBackground() instanceof ColorUIResource)) {
       AluminiumUtils.fillComponent(g, c);
     } else {
       if (parent != null) {
         g.setColor(parent.getBackground());
       } else {
         g.setColor(c.getBackground());
       }
       g.fillRect(0, 0, c.getWidth(), c.getHeight());
     }
   }
 }