Transférer les fichiers vers 'src/fr/sae/JSonInspector/Graphics'

This commit is contained in:
Romain BESSON 2023-01-16 00:11:01 +01:00
parent 77cb91dc32
commit 02588c42ec

View File

@ -1,40 +1,46 @@
package fr.sae.JSonInspector.Graphics;
import java.awt.event.MouseEvent;
import java.awt.event.MouseListener;
public class ArrayObjectListener implements MouseListener {
private final Line line;
private final Frame frame;
public ArrayObjectListener(Line line, Frame frame) {
this.line = line;
this.frame = frame;
}
@Override
public void mouseClicked(MouseEvent e) {
if (line.isShow()) {
line.retreat();
} else {
line.unfold();
}
frame.repaintFile();
}
@Override
public void mousePressed(MouseEvent e) {
}
@Override
public void mouseReleased(MouseEvent e) {
}
@Override
public void mouseEntered(MouseEvent e) {
}
@Override
public void mouseExited(MouseEvent e) {
}
}
package JsonInspector.Graphics;
import java.awt.event.MouseEvent;
import java.awt.event.MouseListener;
public class ArrayObjectListener implements MouseListener {
private final Line line;
private final Frame frame;
/**
*
* @param line La ligne écoutée
* @param frame la frame contenant la ligne écoutée
*/
public ArrayObjectListener(Line line, Frame frame) {
this.line = line;
this.frame = frame;
}
/**
* Change le statut d'affichage de la ligne
* @param e the event to be processed
*/
@Override
public void mouseClicked(MouseEvent e) {
if (line.isShow()) {
line.retreat();
} else {
line.unfold();
}
frame.repaintFile();
}
@Override
public void mousePressed(MouseEvent e) {}
@Override
public void mouseReleased(MouseEvent e) {}
@Override
public void mouseEntered(MouseEvent e) {}
@Override
public void mouseExited(MouseEvent e) {}
}