Esempio n. 1
0
 private void btnAdd_Click(object sender, EventArgs e)
 {
     using (var addForm = new AddTaskGUI(this))
     {
         addForm.ShowDialog();
     }
 }
Esempio n. 2
0
        void listBox_MouseDoubleClick(object sender, MouseEventArgs e)
        {
            var listBox = (ListBox)sender;
            var index   = listBox.IndexFromPoint(e.X, e.Y);
            var task    = (Task)listBox.Items[index];

            if (index != -1)
            {
                using (var addForm = new AddTaskGUI(this))
                {
                    addForm.ShowDetailTask(task);
                    addForm.ShowDialog();
                    addForm.Dispose();
                }
            }
        }