Exemplo n.º 1
0
        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);
        }
Exemplo n.º 2
0
        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);
        }
Exemplo n.º 3
0
        private void btn_Voice_SendSettings_Click(object sender, RoutedEventArgs e)
        {
            VoiceViewModel v = (VoiceViewModel)DataContext;

            v.SendSettings();
        }
Exemplo n.º 4
0
        private void btn_Voice_Stop_Click(object sender, RoutedEventArgs e)
        {
            VoiceViewModel v = (VoiceViewModel)DataContext;

            v.StopTalking();
        }
Exemplo n.º 5
0
        private void btnSpeak_Click(object sender, RoutedEventArgs e)
        {
            VoiceViewModel v = (VoiceViewModel)DataContext;

            v.SendCurrentSentence(this.txtSentence.Text);
        }