List<Note> GetSelectedNotes ()
{
Gtk.TreeModel model;
List<Note> selected_notes = new List<Note> ();
Gtk.TreePath [] selected_rows =
tree.Selection.GetSelectedRows (out model);
foreach (Gtk.TreePath path in selected_rows) {
Note note = GetNote (path);
if (note == null)
continue;
selected_notes.Add (note);
}
return selected_notes;
}