/// <summary> /// Initialization, takes the Addin this gui is attached to. /// </summary> public TaskManagerGui(TaskManagerNoteAddin addin) { this.addin = addin; utils = new TaskNoteUtilities (addin.Buffer); var duedateImage = new Gtk.Image(null, "Tomboy.TaskManager.Icons.duedate-icon22.png"); add_duedate.Image = duedateImage; var priorityImage = new Gtk.Image(null, "Tomboy.TaskManager.Icons.priority-icon22.png"); add_priority.Image = priorityImage; task_menu.Add (add_duedate); task_menu.Add (add_priority); task_menu.Add (show_priority); if (Tomboy.Debugging) { Gtk.MenuItem print_structure = new Gtk.MenuItem (Catalog.GetString ("Print Structure")); print_structure.Activated += OnPrintStructureActivated; task_menu.Add (print_structure); } var todoImage = new Gtk.Image(null, "Tomboy.TaskManager.Icons.todo-icon24.png"); menu_tool_button = new Gtk.MenuToolButton (todoImage, null); menu_tool_button.TooltipText = Catalog.GetString ("Add a new TaskList"); menu_tool_button.ArrowTooltipText = Catalog.GetString ("Set TaskList properties"); menu_tool_button.Menu = task_menu; task_menu.ShowAll (); menu_tool_button.Show (); addin.AddToolItem (menu_tool_button, -1); }
public TaskListParser(Note note) { this.note = note; utils = new TaskNoteUtilities (buffer); }
public void Initialize(TextIter iter, AttributedTaskTag tag) { //this.Buffer = buffer; this.Position = Buffer.CreateMark (null, iter, true); this.Tag = tag; Tag.AttributedTask = this; utils = new TaskNoteUtilities (Buffer); }
/// <summary> /// Loads (in terms of Tasks and Tasklists) the contents of a note /// </summary> public void DeserializeTasklists() { Logger.Debug ("Loading..."); utils = new TaskNoteUtilities (Buffer); //var parser = new TaskListParser(Note); //TaskLists = parser.Parse(); /* Not necessary anymore... * I put the loader into the getter * That way, it's dynamic */ foreach (TaskList tl in TaskLists) { foreach (Task t in tl.Tasks) { t.AddWidgets (); } tl.LockEnd (); } // TODO load "PriorityShown" from the configuration? }