Ejemplo n.º 1
0
        /// <summary>
        ///     Push the task in progress
        /// </summary>
        /// <param name="task"></param>
        public void SetInProgress(SymuTask task)
        {
            if (task is null)
            {
                throw new ArgumentNullException(nameof(task));
            }

            ToDo.Remove(task);
            InProgress.Add(task);
            OnAfterSetTaskInProgress?.Invoke(this, new TaskEventArgs(task));
            // We don't want to track message as Task
            if (task.Parent is Message)
            {
                return;
            }

            TaskResult.ToDo--;
            TaskResult.InProgress++;
        }
Ejemplo n.º 2
0
 /// <summary>
 ///     Clone a task in Progress in TasksManager
 /// </summary>
 /// <param name="sender"></param>
 /// <param name="e"></param>
 private void AfterSetTaskInProgress(object sender, TaskEventArgs e)
 {
     OnAfterSetTaskInProgress?.Invoke(this, new TaskEventArgs(e.Task));
 }