示例#1
0
文件: Form1.cs 项目: naithar/Gamma
 //добавление сеанса
 private void buttonSessionsCreate_Click(object sender, EventArgs e)
 {
     AddSession form = new AddSession("", this);
     form.ShowDialog(this);
     if (dRes == DialogResult.OK)
     {
         saved = false;
         buttonSessionsCancel.Enabled = true;
         buttonSessionsCancel.Enabled = true;
         bufferSessions.Add(new Session(_com, "", 0));
         UpdateSessionComboBoxList();
         currentSession = bufferSessions.Count - 1;
         comboBoxSession.SelectedIndex = currentSession;
         FillSession();
     }
 }
示例#2
0
文件: Form1.cs 项目: naithar/Gamma
 //изменение названия сеанса
 private void button3_Click(object sender, EventArgs e)
 {
     if (currentSession > 1)
     {
         AddSession form = new AddSession(bufferSessions[currentSession].Name, this);
         form.ShowDialog(this);
         if (dRes == DialogResult.OK)
         {
             saved = false;
             buttonSessionsSave.Enabled = true;
             buttonSessionsCancel.Enabled = true;
             bufferSessions[currentSession].Name = _com;
             UpdateSessionComboBoxList();
             FillSession();
         }
     }
 }