Galera eu to com um problema no metodo OvalPanel (linhas 8 e 13).
alguem poderia me ajudar?
obrigado pessoal…
abraço…
[code]import java.awt.;
import java.awt.event.;
import javax.swing.;
import javax.swing.event.;
public class Elipse extends JFrame{
private JSlider diametroSlider;
private OvalPanel meuPanel;
public Elipse(){
super("Elipse");
meuPanel = new OvalPanel();
meuPanel.setBackground(Color.YELLOW);
diametroSlider = new JSlider(SwingConstants.HORIZONTAL,0,200,10);
diametroSlider.setMajorTickSpacing(10);
diametroSlider.setPaintTicks(true);
diametroSlider.addChangeListener(
new ChangeListener(){
public void stateChanged(ChangeEvent e)
{
meuPanel.setDiameter(diametroSlider.getValue());
}
}
);
Container container = getContentPane();
container.add(diametroSlider, BorderLayout.SOUTH);
container.add(meuPanel, BorderLayout.CENTER);
setSize(220,270);
setVisible(true);
}
public static void main (String args[]){
Elipse aplicacao = new Elipse();
aplicacao.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
}
}[/code]