Amélioration des récompenses
This commit is contained in:
@@ -54,7 +54,7 @@ public class Options {
|
||||
|
||||
public static boolean AUTO_FOCUS = true;
|
||||
|
||||
public static final int MAX_TILE_NUMBER = 50;
|
||||
public static final int MAX_TILE_NUMBER = 2;
|
||||
|
||||
public static boolean FULL_SCREEN = false;
|
||||
|
||||
|
@@ -11,6 +11,7 @@ public class RewardsPanel extends JPanel {
|
||||
|
||||
private JTextField usernameField;
|
||||
private JPanel rewardsDisplayPanel;
|
||||
private JScrollPane scrollPane;
|
||||
|
||||
public RewardsPanel() {
|
||||
setLayout(new BorderLayout());
|
||||
@@ -35,8 +36,8 @@ public class RewardsPanel extends JPanel {
|
||||
|
||||
// Panel pour afficher les récompenses
|
||||
rewardsDisplayPanel = new JPanel(new GridLayout(0, 3, 10, 10));
|
||||
JScrollPane scrollPane = new JScrollPane(rewardsDisplayPanel);
|
||||
mainPanel.add(scrollPane, createGridBagConstraints(0, 1, 1));
|
||||
this.scrollPane = new JScrollPane(rewardsDisplayPanel); // Taille minimale pour éviter la réduction
|
||||
mainPanel.add(this.scrollPane, createGridBagConstraints(0, 1, 1));
|
||||
|
||||
// Action du bouton pour afficher les récompenses
|
||||
JButton fetchButton = new JButton("Afficher les récompenses de l'utilisateur");
|
||||
@@ -126,6 +127,9 @@ public class RewardsPanel extends JPanel {
|
||||
noRewardsLabel.setForeground(Color.RED);
|
||||
rewardsDisplayPanel.add(noRewardsLabel);
|
||||
} else {
|
||||
|
||||
this.scrollPane.setPreferredSize(new Dimension(600, 300)); // Ajustez la taille comme nécessaire
|
||||
this.scrollPane.setMinimumSize(new Dimension(600, 300));
|
||||
// Otherwise, display the rewards
|
||||
rewardsDisplayPanel.setLayout(new GridLayout(0, 3, 10, 10));
|
||||
|
||||
|
Reference in New Issue
Block a user