private void RaiseNoteUpdated(NoteViewModel noteViewModel) { if (NoteEdited != null) { NoteEdited(this, new NoteEditedEventArgs(noteViewModel)); } }
public void AddNoteToList(NoteViewModel note) { var listitem = new ListViewItem(note.Title) { ToolTipText = note.Description }; listitem.Tag = note.Id.ToString(); listView1.Items.Add(listitem); }
private void EditNoteInList(NoteViewModel note) { foreach (ListViewItem item in listView1.Items) { if ((string) item.Tag == note.Id.ToString()) { item.Text = note.Title; item.ToolTipText = note.Description; txtHiddenId.Text = note.Id.ToString(); } } listView1.Refresh(); }
public NoteSavedEventArgs(NoteViewModel noteViewModel) { _noteViewModel = noteViewModel; }
public NoteEditedEventArgs(NoteViewModel noteViewModel) { _noteViewModel = noteViewModel; }
public NoteDeletedEventArgs(NoteViewModel noteViewModel) { _noteViewModel = noteViewModel; }