BUT2/DEV/DEV2.1/CM1/Q4_Debut/ActionSouris.java
2023-10-23 13:23:36 +02:00

38 lines
742 B
Java

//Wamster Alexis
import javax.swing.*;
import java.awt.*;
import java.awt.event.*;
public class ActionSouris implements MouseListener{
private JFrame fenetre;
private int rayon;
public ActionSouris(JFrame fenetre, int rayon){
this.fenetre = fenetre;
this.rayon = rayon;
}
public int RecupereRayon(){
return this.rayon;
}
@Override
public void mouseClicked(MouseEvent e){
this.rayon += 15;
fenetre.repaint();
}
@Override
public void mouseEntered(MouseEvent e){
}
@Override
public void mouseExited(MouseEvent e){
}
@Override
public void mousePressed(MouseEvent e){
}
@Override
public void mouseReleased(MouseEvent e){
}
}