/// <summary> /// 全局信息填充及初始化 /// </summary> /// <param name="conferenceInformationEntity">会议信息数据实体</param> /// <param name="callBack"></param> private void GlobleInfoLoadAndInit(ConferenceInformationEntityPC conferenceInformationEntity) { try { TimerJob.StartRun(new Action(() => { if (this.IsDisposeAllSocekt) { if (this.CheckDisposeAllSocketTimer != null) { this.CheckDisposeAllSocketTimer.Stop(); } //模式管理中心 this.Model_ManageCenter(conferenceInformationEntity.EducationMode, conferenceInformationEntity.SimpleMode); //填充全局字段(参会人列表、会议名称、会议ID) this.GlobalDataInit(conferenceInformationEntity); //会话标示服务器判断移除 ModelManage.ConferenceLyncConversation.RemoveConversation(Constant.ConferenceName, new Action <bool>((successed) => { if (successed) { this.canBeginLyncConversationInit = true; } })); //判断是否为会议主持人(是的话设置全局标示) MainPageBase.PresentSetting(conferenceInformationEntity); //共享协作数据准备 this.ConversationDataInitPrepare(); //填充参会人信息 LyncHelper.AddContacts(); //重新进行会话配置 this.Conversation_Configure(); } }), 800, out this.CheckDisposeAllSocketTimer); } catch (Exception ex) { LogManage.WriteLog(this.GetType(), ex); } finally { } }
/// <summary> /// 全局信息填充及初始化 /// </summary> /// <param name="conferenceInformationEntity"></param> /// <param name="callBack"></param> private void GlobleInfoLoadAndInit(ConferenceInformationEntityPC conferenceInformationEntity, Action callBack) { try { TimerJob.StartRun(new Action(() => { if (this.IsDisposeAllSocekt) { if (this.CheckDisposeAllSocketTimer != null) { this.CheckDisposeAllSocketTimer.Stop(); } #region 填充全局字段(参会人列表、会议名称、会议ID) //参会人列表 Constant.ParticipantList = conferenceInformationEntity.JoinPeople.ToList <string>(); //参会名称 Constant.ConferenceName = conferenceInformationEntity.MeetingName; //会议室名称 Constant.ConferenceRoomName = conferenceInformationEntity.RoomName; //会议主持人 Constant.ConferenceHost = conferenceInformationEntity.ApplyPeople; if (conferenceInformationEntity.EducationMode) { //主窗体标题2显示 MainWindow.mainWindow.MainWindowHeader2 = Constant.EducationTittle1 + Constant.ConferenceName; //设置主窗体标题2 MainWindow.mainWindow.MainWindowHeader3 = " " + Constant.EducationTittle2 + Constant.SelfName; } else { //主窗体标题2显示 MainWindow.mainWindow.MainWindowHeader2 = Constant.DiscussTittle1 + Constant.ConferenceName; //设置主窗体标题2 MainWindow.mainWindow.MainWindowHeader3 = " " + Constant.DiscussTittle2 + Constant.SelfName; } //参会ID Constant.MeetingID = conferenceInformationEntity.MeetingID; //网络浏览地址 Constant.WebUri = conferenceInformationEntity.WebUri; //显示参会名称 this.MeetingName = Constant.ConferenceName; //投影大屏幕 Constant.BigScreenName = conferenceInformationEntity.BigScreenName; #endregion #region 会话标示服务器判断移除 ModelManage.ConferenceLyncConversation.RemoveConversation(Constant.ConferenceName, new Action <bool>((successed) => { if (successed) { this.canBeginLyncConversationInit = true; } })); #endregion #region 判断是否为会议主持人(是的话设置全局标示,服务器应用池持续性设置) //判断当前用户是否为主持人(该标示在程序全局上使用) if (Constant.SelfUri.Equals(conferenceInformationEntity.ApplyPeople) || Constant.SelfName.Equals(conferenceInformationEntity.ApplyPeople)) { Constant.IsMeetingPresenter = true; } else { Constant.IsMeetingPresenter = false; } #endregion //填充参会人信息 LyncHelper.AddContacts(); #region 获取服务端口 //获取服务端口 this.GetServicePort(callBack); #endregion #region 重新进行会话配置 TimerJob.StartRun(new Action(() => { if (this.canBeginLyncConversationInit) { this.CheckConversationInitTimer.Stop(); //会话初始化 this.LyncConversationInit(); } }), 1000, out this.CheckConversationInitTimer); #endregion } }), 800, out this.CheckDisposeAllSocketTimer); } catch (Exception ex) { LogManage.WriteLog(this.GetType(), ex); } finally { } }