public void Initialize(IPluginManager pluginMgr) { this.PluginManager = pluginMgr; pendingTasks = new PendingTaskList(); completedTasks = new CompletedTaskList(); AllTasks = new TaskList(pendingTasks, completedTasks); pendingTasks.TaskChanged += PendingTasks_TaskChanged; pendingTasks.TaskTextChanged += PendingTasks_TaskTextChanged; pendingTasks.TaskSelectionChanged += PendingTasks_TaskSelectionChanged; dateTimePicker = new DateTimePicker(); taskListView = new TaskListView(); taskListView.TaskViewEvent += OnTaskViewEvent; pluginMgr.ScheduleTask(new TaskSchedular.RecurringTask( () => { taskListView.Invoke((Action)RefreshTaskListView); }, DateTime.Today.AddDays(1), TimeSpan.FromDays(1), "TaskListRefreshNewDay" ) ); }
public TaskReminder(PendingTaskList taskList, System.Windows.Forms.Control syncControl) { this.taskList = taskList; StartTime = DateTime.Now.AddSeconds(5); TaskId = "TaskReminder"; this.syncControl = syncControl; }
public TaskDueIcon(PendingTaskList taskList) { taskList.TaskChanged += (n, e) => { if (StatusChange == null) { return; } switch (e.TaskChange) { case PendingTaskChange.TaskAdded: case PendingTaskChange.TaskReopened: StatusChange(n, this, SystemIconStatusChange.Show); break; case PendingTaskChange.TaskCompleted: StatusChange(n, this, SystemIconStatusChange.Hide); break; case PendingTaskChange.TaskRemoved: StatusChange(n, this, SystemIconStatusChange.Hide); break; } }; }
public void Initialize(IPluginManager pluginMgr) { this.PluginManager = pluginMgr; pendingTasks = new PendingTaskList(); completedTasks = new CompletedTaskList(); AllTasks = new TaskList(pendingTasks, completedTasks); pendingTasks.TaskChanged += PendingTasks_TaskChanged; pendingTasks.TaskTextChanged += PendingTasks_TaskTextChanged; pendingTasks.TaskSelectionChanged += PendingTasks_TaskSelectionChanged; dateTimePicker = new DateTimePicker(); taskListView = new TaskListView(); taskListView.TaskViewEvent += OnTaskViewEvent; pluginMgr.ScheduleTask(new TaskSchedular.RecurringTask( () => { taskListView.Invoke((Action)RefreshTaskListView); }, DateTime.Today.AddDays(1), TimeSpan.FromDays(1), "TaskListRefreshNewDay" ) ); }