public BBotFrontEndViewModel() { connectionViewModel = new ConnectionViewModel(); voiceViewModel = new VoiceViewModel(connectionViewModel.ConnectionCOMModel); botTerminalViewModel = new BotTerminalViewModel(connectionViewModel.ConnectionCOMModel); legsViewModel = new LegsViewModel(connectionViewModel.ConnectionCOMModel); quickButtonsViewModel = new QuickButtonsViewModel(connectionViewModel.ConnectionCOMModel); eyeViewModel = new EyeViewModel(connectionViewModel.ConnectionCOMModel); //Add widgets to a list //Currently this list isn't used bBotWidgetsList = new List<IRobotWidget>(); bBotWidgetsList.Add(voiceViewModel.VoiceModel); bBotWidgetsList.Add(botTerminalViewModel.BotTerminalModel); bBotWidgetsList.Add(legsViewModel.LegsModel); bBotWidgetsList.Add(quickButtonsViewModel.QuickButtonsModel); bBotWidgetsList.Add(eyeViewModel.EyeModel); }
public BBotFrontEndViewModel() { connectionViewModel = new ConnectionViewModel(); voiceViewModel = new VoiceViewModel(connectionViewModel.ConnectionCOMModel); botTerminalViewModel = new BotTerminalViewModel(connectionViewModel.ConnectionCOMModel); legsViewModel = new LegsViewModel(connectionViewModel.ConnectionCOMModel); quickButtonsViewModel = new QuickButtonsViewModel(connectionViewModel.ConnectionCOMModel); eyeViewModel = new EyeViewModel(connectionViewModel.ConnectionCOMModel); //Add widgets to a list //Currently this list isn't used bBotWidgetsList = new List <IRobotWidget>(); bBotWidgetsList.Add(voiceViewModel.VoiceModel); bBotWidgetsList.Add(botTerminalViewModel.BotTerminalModel); bBotWidgetsList.Add(legsViewModel.LegsModel); bBotWidgetsList.Add(quickButtonsViewModel.QuickButtonsModel); bBotWidgetsList.Add(eyeViewModel.EyeModel); }
private void btn_WalkStop_Click(object sender, RoutedEventArgs e) { LegsViewModel v = ( LegsViewModel )DataContext; v.LegsModel.Throttle_Stop(); }
private void btn_WalkBackward_Click(object sender, RoutedEventArgs e) { LegsViewModel v = ( LegsViewModel )DataContext; v.LegsModel.Throttle_Down(); }