Пример #1
0
 private void btnEncodersAdd_Click(object sender, EventArgs e)
 {
     using (EncoderProgramForm form = new EncoderProgramForm())
     {
         if (form.ShowDialog() == DialogResult.OK)
         {
             VideoEncoder encoder = form.encoder;
             Program.Settings.VideoEncoders.Add(encoder);
             AddVideoEncoder(encoder);
         }
     }
 }
Пример #2
0
 private void btnEncodersAdd_Click(object sender, EventArgs e)
 {
     using (EncoderProgramForm form = new EncoderProgramForm())
     {
         if (form.ShowDialog() == DialogResult.OK)
         {
             VideoEncoder encoder = form.encoder;
             Program.Settings.VideoEncoders.Add(encoder);
             AddVideoEncoder(encoder);
         }
     }
 }
Пример #3
0
        private void btnEncodersEdit_Click(object sender, EventArgs e)
        {
            if (lvEncoders.SelectedItems.Count > 0)
            {
                ListViewItem lvi     = lvEncoders.SelectedItems[0];
                VideoEncoder encoder = lvi.Tag as VideoEncoder;

                using (EncoderProgramForm form = new EncoderProgramForm(encoder))
                {
                    if (form.ShowDialog() == DialogResult.OK)
                    {
                        lvi.Text             = encoder.Name ?? "";
                        lvi.SubItems[1].Text = encoder.Path ?? "";
                        lvi.SubItems[2].Text = encoder.Args ?? "";
                        lvi.SubItems[3].Text = encoder.OutputExtension ?? "";
                    }
                }
            }
        }
Пример #4
0
        private void btnEncodersEdit_Click(object sender, EventArgs e)
        {
            if (lvEncoders.SelectedItems.Count > 0)
            {
                ListViewItem lvi = lvEncoders.SelectedItems[0];
                VideoEncoder encoder = lvi.Tag as VideoEncoder;

                using (EncoderProgramForm form = new EncoderProgramForm(encoder))
                {
                    if (form.ShowDialog() == DialogResult.OK)
                    {
                        lvi.Text = encoder.Name ?? "";
                        lvi.SubItems[1].Text = encoder.Path ?? "";
                        lvi.SubItems[2].Text = encoder.Args ?? "";
                        lvi.SubItems[3].Text = encoder.OutputExtension ?? "";
                    }
                }
            }
        }