Tomboy.NoteRecentChanges.GetSelectedNotebook C# (CSharp) Method

GetSelectedNotebook() public method

Returns the currently selected notebook in the "Search All Notes Window".
public GetSelectedNotebook ( ) : Tomboy.Notebooks.Notebook
return Tomboy.Notebooks.Notebook
		public Notebooks.Notebook GetSelectedNotebook ()
		{
			Gtk.TreeModel model;
			Gtk.TreeIter iter;

			Gtk.TreeSelection selection = notebooksTree.Selection;
			if (selection == null || selection.GetSelected (out model, out iter) == false)
				return null; // Nothing selected

			return model.GetValue (iter, 0) as Notebooks.Notebook;
		}