diff --git a/Application/Clavardage/src/view/Interface.java b/Application/Clavardage/src/view/Interface.java index 678c69c..8ab2055 100644 --- a/Application/Clavardage/src/view/Interface.java +++ b/Application/Clavardage/src/view/Interface.java @@ -31,7 +31,7 @@ public class Interface implements ActionListener { PseudotextField = new JTextField(); //Pseudo setup PseudotextField.setColumns(10); PseudotextField.addActionListener(this); - Pseudolabel = new JLabel("Enter username: "); + Pseudolabel = new JLabel("Your current username is: " + hisController.getMyUser().getPseudo()); Pseudolabel.setLabelFor(PseudotextField); MessagetextField = new JTextField(); //Messages setup @@ -76,7 +76,12 @@ public class Interface implements ActionListener { Pseudolabel.setText("Your current username is: " + Textinput); MessagetextField.setVisible(true); Messagelabel.setVisible(true); - //TODO Appeler setPseudo(TextInput) à chaque fois + try { + hisController.changePseudo(); + } catch (IOException e1) { + // TODO Auto-generated catch block + e1.printStackTrace(); + } }else if(e.getSource() == MessagetextField){ //Messages String Textinput = MessagetextField.getText(); Messagelabel.setText("Message: " + Textinput); @@ -163,5 +168,4 @@ public class Interface implements ActionListener { } }); }*/ -} - +} \ No newline at end of file