Correction des bugs de verions entre Windows, Linux et macOS
This commit is contained in:
parent
62a90389ca
commit
0cc2067922
4
Makefile
4
Makefile
@ -13,7 +13,7 @@ JCFLAGS := -encoding UTF-8 -implicit:none
|
||||
JVM := java
|
||||
JVMFLAGS :=
|
||||
|
||||
SRCDIR := ./src/GridMaker
|
||||
SRCDIR := ./src/GridSolver
|
||||
OUTDIR := ./out
|
||||
DOCDIR := ./doc
|
||||
SRC := $(wildcard $(SRCDIR)/*.java)
|
||||
@ -42,4 +42,4 @@ doc :
|
||||
|
||||
.PHONY : run clean doc
|
||||
|
||||
### FIN ###
|
||||
### FIN ###
|
@ -19,6 +19,17 @@ public class Button extends JButton {
|
||||
setBackground(new Color(96, 175, 255));
|
||||
}
|
||||
|
||||
/**
|
||||
* Constructor
|
||||
* @param text The text of the button
|
||||
* @param color The background color of the button
|
||||
*/
|
||||
public Button (String text,Color color) {
|
||||
super(text);
|
||||
setFont(new Font("Arial", Font.BOLD, 15));
|
||||
setBackground(color);
|
||||
}
|
||||
|
||||
/**
|
||||
* Constructor
|
||||
* @param text The text of the button
|
||||
|
@ -72,7 +72,7 @@ public class HomeView extends JPanel {
|
||||
buttonPanel.setBackground(BACKGROUND_COLOR);
|
||||
HomeButtonClickListener listenerButton = new HomeButtonClickListener(window);
|
||||
for (String text : BUTTON_TEXTS) {
|
||||
Button button = new Button(text, BUTTON_SIZE, BUTTON_FONT, BACKGROUND_COLOR);
|
||||
Button button = new Button(text, BUTTON_SIZE, BUTTON_FONT, Color.white);
|
||||
button.addActionListener(listenerButton);
|
||||
buttonPanel.add(button);
|
||||
}
|
||||
|
@ -18,6 +18,17 @@ public class Button extends JButton {
|
||||
setFont(new Font("Arial", Font.BOLD, 15));
|
||||
setBackground(new Color(96, 175, 255));
|
||||
}
|
||||
|
||||
/**
|
||||
* Constructor
|
||||
* @param text The text of the button
|
||||
* @param color The background color of the button
|
||||
*/
|
||||
public Button (String text,Color color) {
|
||||
super(text);
|
||||
setFont(new Font("Arial", Font.BOLD, 15));
|
||||
setBackground(color);
|
||||
}
|
||||
|
||||
/**
|
||||
* Constructor
|
||||
|
@ -43,10 +43,10 @@ public class GSMenu {
|
||||
this.buttonPanel.setBackground(new Color(54, 91, 109));
|
||||
|
||||
// Création des boutons
|
||||
this.importerButton = new Button("Charger une grille");
|
||||
this.jouerButton = new Button("Jouer");
|
||||
this.importerButton = new Button("Charger une grille",Color.white);
|
||||
this.jouerButton = new Button("Jouer",Color.white);
|
||||
this.jouerButton.setEnabled(false); // Le bouton "Jouer" est désactivé par défaut
|
||||
this.autoSolveButton = new Button("Résolution automatique");
|
||||
this.autoSolveButton = new Button("Résolution automatique",Color.white);
|
||||
this.autoSolveButton.setEnabled(false); // Le bouton "Résolution automatique" est désactivé par défaut
|
||||
|
||||
// Ajout des boutons au panneau de boutons
|
||||
|
@ -72,7 +72,7 @@ public class HomeView extends JPanel {
|
||||
buttonPanel.setBackground(BACKGROUND_COLOR);
|
||||
HomeButtonClickListener listenerButton = new HomeButtonClickListener(window);
|
||||
for (String text : BUTTON_TEXTS) {
|
||||
Button button = new Button(text, BUTTON_SIZE, BUTTON_FONT, BACKGROUND_COLOR);
|
||||
Button button = new Button(text, BUTTON_SIZE, BUTTON_FONT, Color.white);
|
||||
button.addActionListener(listenerButton);
|
||||
buttonPanel.add(button);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user