private static Job ReconfigureJob(Job j) { if (!(j is MuxJob)) { return(null); } MuxJob m = (MuxJob)j; MuxWindow w = new MuxWindow( MainForm.Instance.MuxProvider.GetMuxer(m.MuxType), MainForm.Instance); w.Job = m; if (w.ShowDialog() == DialogResult.OK) { return(w.Job); } else { return(m); } }
private static Job ReconfigureJob(Job j) { if (!(j is MuxJob)) return null; MuxJob m = (MuxJob)j; MuxWindow w = new MuxWindow( MainForm.Instance.MuxProvider.GetMuxer(m.MuxType), MainForm.Instance); w.Job = m; if (w.ShowDialog() == DialogResult.OK) return w.Job; else return m; }
private void mnuMuxer_Click(object sender, System.EventArgs e) { if ((!(sender is System.Windows.Forms.MenuItem)) || (!((sender as MenuItem).Tag is IMuxing))) return; using (MuxWindow mw = new MuxWindow((IMuxing)((sender as MenuItem).Tag),this)) { if (mw.ShowDialog() == DialogResult.OK) { MuxJob job = mw.Job; Jobs.addJobsToQueue(job); } } }