Develop #10

Merged
SemvdH merged 229 commits from develop into master 2020-10-29 22:50:49 +00:00
4 changed files with 8 additions and 8 deletions
Showing only changes of commit e09f4f1325 - Show all commits

View File

@@ -28,7 +28,7 @@ namespace ClientApp.ViewModels
internal void setLoginStatus(bool status)
{
this.mainWindowViewModel.infoModel.ConnectedToServer = true;
this.mainWindowViewModel.InfoModel.ConnectedToServer = true;
if (status)
{
this.mainWindowViewModel.SelectedViewModel = new MainViewModel(mainWindowViewModel);

View File

@@ -18,12 +18,12 @@ namespace ClientApp.ViewModels
this.RetryServerCommand = new RelayCommand(() =>
{
//try connect server
this.MainWindowViewModel.infoModel.ConnectedToServer = true;
this.MainWindowViewModel.InfoModel.ConnectedToServer = true;
});
this.RetryVREngineCommand = new RelayCommand(() =>
{
//try connect vr-engine
this.MainWindowViewModel.infoModel.ConnectedToVREngine = true;
this.MainWindowViewModel.InfoModel.ConnectedToVREngine = true;
});
}
}

View File

@@ -8,14 +8,14 @@ namespace ClientApp.ViewModels
{
class MainWindowViewModel : ObservableObject
{
public Info infoModel { get; set; }
public Info InfoModel { get; set; }
public ObservableObject SelectedViewModel { get; set; }
public Client client { get; }
public MainWindowViewModel(Client client)
{
this.infoModel = new Info();
this.InfoModel = new Info();
this.client = client;
LoginViewModel loginViewModel = new LoginViewModel(this);
SelectedViewModel = loginViewModel;

View File

@@ -21,17 +21,17 @@
<StackPanel Grid.Column="0" Grid.Row="0" Orientation="Horizontal" Margin="10">
<Label Content="Connected to server:"/>
<Label Content="{Binding Path=MainWindowViewModel.infoModel.ConnectToServer}"/>
<Label Content="{Binding Path=MainWindowViewModel.InfoModel.ConnectedToServer}"/>
</StackPanel>
<StackPanel Grid.Column="1" Grid.Row="0" Orientation="Horizontal" Margin="10">
<Label Content="Connected to VR-Engine:"/>
<Label Content="{Binding Path=MainWindowViewModel.infoModel.ConnectedToVREngine}"/>
<Label Content="{Binding Path=MainWindowViewModel.InfoModel.ConnectedToVREngine}"/>
</StackPanel>
<StackPanel Grid.Column="2" Grid.Row="0" Orientation="Horizontal" Margin="10">
<Label Content="Doctor connected:"/>
<Label Content="{Binding Path=MainWindowViewModel.infoModel.DoctorConnected}"/>
<Label Content="{Binding Path=MainWindowViewModel.InfoModel.DoctorConnected}"/>
</StackPanel>
<Button Grid.Column="0" Grid.Row="1" Command="{Binding RetryServerCommand}" Width="50" Height="20">