création de l'exécutable

This commit is contained in:
Louis Farina 2021-02-13 16:32:11 +01:00
parent 018624b364
commit 7e455e7606
4 changed files with 5 additions and 3 deletions

1
.gitignore vendored
View file

@ -1,3 +1,2 @@
/bin/
*.jar
*.class

BIN
Projet.jar Normal file

Binary file not shown.

View file

@ -48,7 +48,7 @@ public class ClientWindow implements ActionListener {
{
username = JOptionPane.showInputDialog(chatWindow,
"Enter a username",
"POPUPOPOPUPUPOPOPUP",
"Login",
JOptionPane.PLAIN_MESSAGE);
connected = network.connect(username);

View file

@ -364,7 +364,10 @@ public class NetworkClient {
ServerSocket s1 = new ServerSocket(portNumber);
(new ListenerStartThread(s1, dest_sockets)).start();
Socket s2 = new Socket("25.67.234.235", portNumber);
Socket s2 = new Socket(getLocalIP(), portNumber);
/*Attention, getLocalIP ne marche que sur un même réseau physique
* pour tester avec Hamachi, il faut hardcoder les IP
*/
(new ReceiveThread(user, s2, chatText, known_users, knownUsersPanel, dest_sockets)).start();
}
catch(IOException e)