コード例 #1
0
 private void Edit()
 {
     using (NotesDescription notesDescription = new NotesDescription(JournalTask.EntryMode.edit, selectedId, layer))
     {
         notesDescription.OnNotesSaved += OnNotesSaved;
         notesDescription.ShowDialog();
     }
 }
コード例 #2
0
 private void Add_Notes()
 {
     using (NotesDescription notes = new NotesDescription(JournalTask.EntryMode.add, id, layer))
     {
         notes.OnNotesSaved += this.OnNotesSaved;
         notes.ShowDialog();
     }
 }
コード例 #3
0
        private void Edit()
        {
            if (tabControl1.SelectedIndex == 1)
            {
                using (CurrentTaskDescription currentTaskDescription = new CurrentTaskDescription(JournalTask.EntryMode.edit, taskId, 0))
                {
                    currentTaskDescription.OnCurrentTaskSaved += OnSave;
                    currentTaskDescription.ShowDialog();
                }
            }

            if (tabControl1.SelectedIndex == 2)
            {
                using (MonthlyTaskDescription monthlyTaskDescription = new MonthlyTaskDescription(JournalTask.EntryMode.edit, taskId, 0))
                {
                    monthlyTaskDescription.OnMonthlyTaskSaved += OnSave;
                    monthlyTaskDescription.ShowDialog();
                }
            }

            if (tabControl1.SelectedIndex == 3)
            {
                using (FutureTaskDescription futureTaskDescription = new FutureTaskDescription(JournalTask.EntryMode.edit, taskId, 0))
                {
                    futureTaskDescription.OnFutureTaskSaved += OnSave;
                    futureTaskDescription.ShowDialog();
                }
            }

            if (tabControl1.SelectedIndex == 4)
            {
                using (NotesDescription notesDescription = new NotesDescription(JournalTask.EntryMode.edit, taskId, 0))
                {
                    notesDescription.OnNotesSaved += OnSave;
                    notesDescription.ShowDialog();
                }
            }
        }