private note_item add_note_header(string line_id, string note_id, bool deleted, DateTime utc_added) { Debug.Assert(note_id != ""); Debug.Assert(line_id != cur_line_id_ && lines_.ContainsKey(line_id)); var new_ = new note_item(this, note_id, line_id, deleted, utc_added ); notes_sorted_by_line_index_.Add(new_); add_note_to_ui(new_); return new_; }