/// <summary> /// Constructor /// </summary> /// <param name="archiver"></param> public frmArchiveConf(IArchiveServer archiver, FMain refFMain) { InitializeComponent(); this.archiver = archiver; this.refFMain = refFMain; PopulateConferences(); }
/// <summary> /// Constructor /// </summary> /// <param name="archiver"></param> public frmArchiveConf( IArchiveServer archiver, FMain refFMain ) { InitializeComponent(); this.archiver = archiver; this.refFMain = refFMain; PopulateConferences(); }
public frmArchiveClient(IArchiveServer archiver, ArchiveService.Conference conference, int[] streams, FMain refFMain, frmArchiveConf refFrmArchiveConf) { InitializeComponent(); // Duration of the current conference totalDuration = conference.End - conference.Start; sliderRange = tbPlayBack.Maximum - tbPlayBack.Minimum; ratioTickBySlider = totalDuration.Ticks / sliderRange; Streams = streams; this.archiver = archiver; this.conference = conference; this.refFMain = refFMain; this.refFrmArchiveConf = refFrmArchiveConf; }
public frmArchiveClient(IArchiveServer archiver, ArchiveService.Conference conference, int[] streams, FMain refFMain, frmArchiveConf refFrmArchiveConf) { InitializeComponent(); // Duration of the current conference totalDuration = conference.End - conference.Start; sliderRange = tbPlayBack.Maximum - tbPlayBack.Minimum; ratioTickBySlider = totalDuration.Ticks / sliderRange; Streams = streams; this.archiver = archiver; this.conference = conference; this.refFMain = refFMain; this.refFrmArchiveConf = refFrmArchiveConf; }
/// <summary> /// Stop the current recording. /// </summary> internal void StopRecording() { try { if (this.archiverState == ArchiverState.Recording) { if (archiver != null && Conference.ActiveVenue != null) { int refs = archiver.StopRecording(Conference.ActiveVenue.EndPoint); archiver = null; if (refs > 0) { MessageBox.Show(this, "Recording will continue, as other participants have requested this recording as well." + "\n When the recording participant leaves, recording has stopped.", "Recording not stopped."); } else if (refs == 0) { MessageBox.Show(this, "Recording has stopped. To ensure proper playback after the initial recording, make sure \n" + "all participants leave the venue before choosing to play back the recording.", "Recording Stopped", MessageBoxButtons.OK, MessageBoxIcon.Information); } else // refs < 0 (i.e. error) { MessageBox.Show(this, "Warning: Recording was already stopped! Either there was an error on the server, or the" + "\n venue had been empty for some amount of time and recording automatically stopped.", "Recording stopped prematurely.", MessageBoxButtons.OK, MessageBoxIcon.Warning); } } this.archiverState = ArchiverState.Stopped; } } catch (Exception ex) { archiverState = ArchiverState.Stopped; MessageBox.Show(this, "The Archive Service is currently unavailable\n" + "or may have encountered an unexpected error.\n" + "Please contact your server's administrator.\n\nException:\n" + ex.ToString(), "Archive Service Error", MessageBoxButtons.OK, MessageBoxIcon.Error); } SetArchiverMenuStatus(); }
/// <summary> /// Stop the playback. /// </summary> internal void StopPlayBack() { if (archiver != null && Conference.ActiveVenue != null) { IPEndPoint remoteVenue; // find the remote venue, which is different from out venue in unicast playback if (MSR.LST.Net.Utility.IsMulticast(Conference.ActiveVenue.EndPoint)) { remoteVenue = Conference.ActiveVenue.EndPoint; } else { remoteVenue = new IPEndPoint(Conference.RtpSession.MulticastInterface, Conference.ActiveVenue.EndPoint.Port); } archiver.StopPlaying(remoteVenue); archiver = null; } this.archiverState = ArchiverState.Stopped; // Reset the status message to participants this.DisplayParticipantCount(); }
/// <summary> /// Creates a new IArchiveServer object to make remote calls to. /// </summary> internal void GetNewArchiver() { if (archiveServiceDefault != null) { try { object factoryObj = Activator.GetObject(typeof(IArchiveServer), GetArchiveUri() + "/ArchiveServer"); this.archiver = (IArchiveServer)factoryObj; } catch (Exception ex) { archiverState = ArchiverState.Unavailable; MessageBox.Show(this, "The Archive Service is currently unavailable\n" + "or may have encountered an unexpected error.\n" + "Please contact your server's administrator.\n\nException:\n" + ex.ToString(), "Archive Service Error", MessageBoxButtons.OK, MessageBoxIcon.Error); } } SetArchiverMenuStatus(); }
public FMain() { InitializeComponent(); archiver = null; }
public FMain() { InitializeComponent(); diagnosticPanel = new StatusBarPanel(); diagnosticPanel.Icon = redLight; diagnosticPanel.AutoSize = StatusBarPanelAutoSize.Contents; diagnosticPanel.ToolTipText = Strings.MulticastNotDetected; messagePanel = new StatusBarPanel(); messagePanel.AutoSize = StatusBarPanelAutoSize.Spring; statusBar.Panels.Add(messagePanel); statusBar.Panels.Add(diagnosticPanel); monitor = new HeartbeatMonitor(); monitor.ProgressChanged += new ProgressChangedEventHandler(monitor_ProgressChanged); archiver = null; }
/// <summary> /// Stop the current recording. /// </summary> internal void StopRecording() { try { if (this.archiverState == ArchiverState.Recording) { if (archiver != null && Conference.ActiveVenue != null) { int refs = archiver.StopRecording(Conference.ActiveVenue.EndPoint); archiver = null; if (refs > 0) { RtlAwareMessageBox.Show(this, Strings.RecordingNotStoppedText, Strings.RecordingNotStoppedTitle, MessageBoxButtons.OK, MessageBoxIcon.None, MessageBoxDefaultButton.Button1, (MessageBoxOptions)0); } else if (refs == 0) { RtlAwareMessageBox.Show(this, Strings.RecordingStoppedText, Strings.RecordingStoppedTitle, MessageBoxButtons.OK, MessageBoxIcon.Information, MessageBoxDefaultButton.Button1, (MessageBoxOptions)0); } else // refs < 0 (i.e. error) { RtlAwareMessageBox.Show(this, Strings.RecordingStoppedPrematurelyText, Strings.RecordingStoppedPrematurelyTitle, MessageBoxButtons.OK, MessageBoxIcon.Warning, MessageBoxDefaultButton.Button1, (MessageBoxOptions)0); } } this.archiverState = ArchiverState.Stopped; } } catch (Exception ex) { archiverState = ArchiverState.Stopped; RtlAwareMessageBox.Show(this, string.Format(CultureInfo.CurrentCulture, Strings.ArchiveServiceErrorText, ex.ToString()), Strings.ArchiveServiceErrorTitle, MessageBoxButtons.OK, MessageBoxIcon.Error, MessageBoxDefaultButton.Button1, (MessageBoxOptions)0); } SetArchiverMenuStatus(); }
/// <summary> /// Creates a new IArchiveServer object to make remote calls to. /// </summary> internal void GetNewArchiver() { if (archiveServiceDefault != null) { try { object factoryObj = Activator.GetObject(typeof(IArchiveServer), GetArchiveUri() + "/ArchiveServer"); this.archiver = (IArchiveServer)factoryObj; } catch (Exception ex) { archiverState = ArchiverState.Unavailable; RtlAwareMessageBox.Show(this, string.Format(CultureInfo.CurrentCulture, Strings.ArchiveServiceErrorText, ex.ToString()), Strings.ArchiveServiceErrorTitle, MessageBoxButtons.OK, MessageBoxIcon.Error, MessageBoxDefaultButton.Button1, (MessageBoxOptions)0); } } SetArchiverMenuStatus(); }