Esempio n. 1
0
        private void BoutDescendre_Click(object sender, EventArgs e)
        {
            if (PanelTask.PanSelected != 0)
            {
                PanelTask tmp = ListePanneaux[PanelTask.PanSelected];
                ListePanneaux[PanelTask.PanSelected]     = ListePanneaux[PanelTask.PanSelected - 1];
                ListePanneaux[PanelTask.PanSelected - 1] = tmp;
                PanelTask.PanSelected--;

                PanListTask.Controls.Clear();
                foreach (var i in ListePanneaux)
                {
                    PanListTask.Controls.Add(i);
                }
                RefreshList();
            }
        }
Esempio n. 2
0
        private void BoutMonter_Click(object sender, EventArgs e)
        {
            if (PanelTask.PanSelected != ListePanneaux.Count - 1)
            {
                PanelTask tmp = ListePanneaux[PanelTask.PanSelected];
                ListePanneaux[PanelTask.PanSelected]     = ListePanneaux[PanelTask.PanSelected + 1];
                ListePanneaux[PanelTask.PanSelected + 1] = tmp;
                PanelTask.PanSelected++;

                PanListTask.Controls.Clear();
                foreach (var i in ListePanneaux)
                {
                    PanListTask.Controls.Add(i);
                }
                RefreshList();
            }
        }