private void LoadedAsync() { var openedViews = _viewLayoutService.ViewFrameList.Where(v => v.IsOpened); var attendees = from openedView in openedViews select new AttendeeItem() { Text = openedView.ViewName, Id = openedView.PhoneId, Hwnd = openedView.Hwnd, ButtonCommand = DelegateCommand <AttendeeItem> .FromAsyncHandler(async (attendeeItem) => { var specialView = _viewLayoutService.ViewFrameList.FirstOrDefault( v => v.PhoneId == attendeeItem.Id && v.Hwnd == attendeeItem.Hwnd); if (!CheckIsUserSpeaking(specialView, true)) { return; } _viewLayoutService.SetSpecialView(specialView, _targetSpecialViewType); await _viewLayoutService.LaunchLayout(); _selectAttendeeListView.Close(); }) }; attendees.ToList().ForEach(attendee => { AttendeeItems.Add(attendee); }); InputSimulatorManager.Instance.Simulator.Keyboard.KeyPress(VirtualKeyCode.TAB); //InputSimulatorManager.Instance.Simulator.Keyboard.KeyPress(VirtualKeyCode.TAB); }
private async Task FullScreenViewChangedAsync(ViewFrame fullScreenView) { if (!CheckIsUserSpeaking(true)) { return; } if (!CheckIsUserSpeaking(fullScreenView, true)) { return; } _viewLayoutService.ChangeViewMode(ViewMode.Closeup); _viewLayoutService.SetSpecialView(fullScreenView, SpecialViewType.FullScreen); await _viewLayoutService.LaunchLayout(); }