private void TrimScoreNotes(ScoreBar willBeDeleted, bool modifiesModel) { // Reposition after calling this function. var bar = willBeDeleted.Bar; Func <ScoreNote, bool> matchFunc = scoreNote => scoreNote.Note.Bar == bar; var processing = ScoreNotes.Where(matchFunc).ToArray(); foreach (var scoreNote in processing) { RemoveScoreNote(scoreNote, modifiesModel, false); } }
public IEnumerable <ScoreNote> GetSelectedScoreNotes() { return(ScoreNotes.Where(scoreNote => scoreNote.IsSelected)); }