private void LoadedAsync()
        {
            List <Participant> participants = new List <Participant>();

            participants.Add(_windowManager.Participant);

            foreach (var participant in _windowManager.Participants)
            {
                participants.Add(participant);
            }

            var attendees = from p in participants
                            select new AttendeeItem()
            {
                Text = p.Account.AccountName,
                Id   = p.Account.AccountId.ToString(),
                //Hwnd = videobox.Handle,
                ButtonCommand = new DelegateCommand <AttendeeItem>((attendeeItem) =>
                {
                    _windowManager.VideoBoxManager.SetProperty(_targetSpecialViewType.ToString(), attendeeItem.Text);


                    _windowManager.LayoutChange(WindowNames.MainWindow, _targetSpecialViewType);
                    _selectAttendeeListView.Close();
                })
            };

            attendees.ToList().ForEach(attendee =>
            {
                AttendeeItems.Add(attendee);
            });

            InputSimulatorManager.Instance.Simulator.Keyboard.KeyPress(VirtualKeyCode.TAB);
            //InputSimulatorManager.Instance.Simulator.Keyboard.KeyPress(VirtualKeyCode.TAB);
        }
Ejemplo n.º 2
0
        private void SetSpecialViewAsync(TextWithButtonItem attendeeViewItem)
        {
            var specialView = _windowManager.VideoBoxManager.Items.FirstOrDefault(v => v.AccountResource != null && v.AccountResource.AccountModel.AccountId.ToString() == attendeeViewItem.Id && v.Handle == attendeeViewItem.Hwnd);

            if (specialView == null)
            {
                MessageQueueManager.Instance.AddWarning("找不到该视图!");
                return;
            }

            _windowManager.VideoBoxManager.SetProperty(_targetPictureMode.ToString(), specialView.Name);

            try
            {
                if (!_windowManager.LayoutChange(WindowNames.MainWindow, _targetPictureMode))
                {
                    MessageQueueManager.Instance.AddError("无法设置一大一小画面模式!");
                }
                //if (_windowManager.LayoutChange(WindowNames.ExtendedWindow, _targetPictureMode))
                //{
                //}
            }
            catch (Exception ex)
            {
                MessageQueueManager.Instance.AddError(ex.Message);
            }
        }
Ejemplo n.º 3
0
        public ILayoutRenderer Create(LayoutRenderType type)
        {
            ILayoutRenderer layoutRenderrer = IoC.Get <ILayoutRenderer>(type.ToString());

            return(layoutRenderrer);
        }
Ejemplo n.º 4
0
        private string GetSpecialVideoBoxName(LayoutRenderType layoutRenderType)
        {
            string specialVideoBoxName = Properties.GetValueOrDefault(layoutRenderType.ToString()) as string;

            return(specialVideoBoxName);
        }