void NovaAnotacaoToolStripMenuItemClick(object sender, EventArgs e) { var frCategoryList = new frCategoryList(); if (frCategoryList.ShowDialog() == DialogResult.OK) { var note = noteDao.createNew(frCategoryList.CategoryId); populate_lvAnnotations(note.Id); edTitle.Select(); } }
void MiAlterarCategoriaClick(object sender, EventArgs e) { var frCategoryList = new frCategoryList(); if (frCategoryList.ShowDialog() == DialogResult.OK) { var note = noteDao.get((int)lvAnnotations.SelectedItems[0].Tag); note.CategoryId = frCategoryList.CategoryId; noteDao.update(note); populate_lvAnnotations(note.Id); } }