private void TaskListView_Load(object sender, EventArgs e)
        {
            var tasks = ToDoAPI.GetTasks();

            foreach (var task in tasks)
            {
                var taskView = new TaskViewModel(task);
                taskView.TaskDelete += OnTaskDelete;
                flowLayoutPanel1.Controls.Add(taskView.taskControl);
            }
        }
        public void ReLoad()
        {
            var oldScrollPosition = flowLayoutPanel1.VerticalScroll.Value;

            var tasks = ToDoAPI.GetTasks();

            flowLayoutPanel1.Controls.Clear();
            foreach (var task in tasks)
            {
                var taskView = new TaskViewModel(task);
                taskView.TaskDelete += OnTaskDelete;
                flowLayoutPanel1.Controls.Add(taskView.taskControl);
            }

            flowLayoutPanel1.VerticalScroll.Value = oldScrollPosition;
        }