// Decompiled by Jad v1.5.7f. Copyright 2000 Pavel Kouznetsov.
// Jad home page: http://www.geocities.com/SiliconValley/Bridge/8617/jad.html
// Decompiler options: packimports(3) 
// Source File Name:   RoundedComponent.java

import java.applet.Applet;
import java.awt.*;

public class RoundedComponent extends Panel
{

    RoundedComponent(int i, int j, int k, int l, int i1)
    {
        reshape(i, j, k, l);
        currentColor = col[i1];
        currentRnd = rnd[i1];
        setBackground(currentColor);
    }

    public void paint(Graphics g)
    {
        if(currentRnd != null)
            g.drawImage(currentRnd, 0, 0, this);
    }

    void setColor(int i)
    {
        currentColor = col[i];
        currentRnd = rnd[i];
        repaint();
    }

    static void staticInit(Applet applet)
    {
        rnd[0] = Const.getImage("rnd1.gif");
        rnd[1] = Const.getImage("rnd2.gif");
        rnd[2] = Const.getImage("rnd0.gif");
    }

    public void update(Graphics g)
    {
        paint(g);
    }

    static Image rnd[] = new Image[3];
    static Color col[] = {
        new Color(198, 198, 255), new Color(140, 140, 255), new Color(255, 174, 174)
    };
    Image currentRnd;
    Color currentColor;

}
