diff --git a/Client/Client.cs b/Client/Client.cs index 87ac03d..17551de 100644 --- a/Client/Client.cs +++ b/Client/Client.cs @@ -17,7 +17,7 @@ namespace Client public int Port = 5555; public bool Connected = false; //TODO send login packet to server with ClientServerUtil.createpayload(0x01,dynamic json with username) - public string username; + public string Username { get; } public Client() { @@ -81,6 +81,7 @@ namespace Client string textUsername = combo.Item1; string textMsg = combo.Item2; //TODO display username and message in chat window + break; case 0x03: diff --git a/Client/Models/Model.cs b/Client/Models/Model.cs index 6fb46cb..59b3577 100644 --- a/Client/Models/Model.cs +++ b/Client/Models/Model.cs @@ -12,12 +12,10 @@ namespace Client private int _numbers; private bool _status; + //Test code public int Numbers { - get - { - return _numbers; - } + get { return _numbers; } set { diff --git a/Client/ViewModels/ViewModel.cs b/Client/ViewModels/ViewModel.cs index 67bc890..241b520 100644 --- a/Client/ViewModels/ViewModel.cs +++ b/Client/ViewModels/ViewModel.cs @@ -12,8 +12,6 @@ namespace Client { public event PropertyChangedEventHandler PropertyChanged; - - public ViewModel() { _model = new Model(); @@ -63,9 +61,5 @@ namespace Client get { return _lobbies; } set { _lobbies = value; } } - - - - } } diff --git a/Client/ViewModels/ViewModelGame.cs b/Client/ViewModels/ViewModelGame.cs index 831253b..2d12d4f 100644 --- a/Client/ViewModels/ViewModelGame.cs +++ b/Client/ViewModels/ViewModelGame.cs @@ -1,16 +1,10 @@ -using System; -using System.Collections.Generic; +using System.Collections.ObjectModel; using System.ComponentModel; -using System.Text; namespace Client.ViewModels { class ViewModelGame : INotifyPropertyChanged { public event PropertyChangedEventHandler PropertyChanged; - - - - } } diff --git a/Client/Views/GameWindow.xaml b/Client/Views/GameWindow.xaml index ddb835f..e896679 100644 --- a/Client/Views/GameWindow.xaml +++ b/Client/Views/GameWindow.xaml @@ -15,7 +15,8 @@ - + + @@ -34,17 +35,22 @@ -