From f44d748a43a76ce60c1989f46729f802a2ab399e Mon Sep 17 00:00:00 2001 From: besson Date: Fri, 2 Dec 2022 09:16:02 +0100 Subject: [PATCH] =?UTF-8?q?Mise=20=C3=A0=20jour=20de=20'src/Test/MainMenu.?= =?UTF-8?q?java'?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/Test/MainMenu.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Test/MainMenu.java b/src/Test/MainMenu.java index 41800cf..58112d2 100644 --- a/src/Test/MainMenu.java +++ b/src/Test/MainMenu.java @@ -204,14 +204,14 @@ public class MainMenu extends JFrame { JButton origin = (JButton) e.getSource(); createJMenuBar(); - if (origin.getText().equals("Admin")) { + if (origin.getText().equals(viewName[0])) { this.setTitle(viewName[0]); menuBar.setBackground(Color.RED); adminPanel.setLayout(adminCards); adminPanel.add(cardWithTable(adminView())); cardIndex = 1; - } else if (origin.getText().equals("Prof")) { + } else if (origin.getText().equals(viewName[1])) { this.setTitle(viewName[1]); menuBar.setBackground(Color.MAGENTA); profPanel.setLayout(profCards);