Example #1
0
        public void DisplayPanelItemSorted(List <int> items)
        {
            ClearPanelItem();
            //sortedItems.Clear();
            int number = 0;

            foreach (var value in items)
            {
                var sortedItem = new SortedItem(value, number);
                //sortedItems.Add(sortedItem);
                panelItemSorted.Controls.Add(sortedItem.ItemVerticalProgressBar);
                panelItemSorted.Controls.Add(sortedItem.ItemLabel);
                number++;
            }
            panelItemSorted.Refresh();
        }
Example #2
0
        public void DisplayPanelItemSorted(List <int> items, out List <SortedItem> sortedItems)
        {
            var result = new List <SortedItem>();

            ClearPanelItem();
            int number = 0;

            foreach (var value in items)
            {
                var sortedItem = new SortedItem(value, number);
                result.Add(sortedItem);
                panelItemSorted.Controls.Add(sortedItem.ItemVerticalProgressBar);
                panelItemSorted.Controls.Add(sortedItem.ItemLabel);
                number++;
            }
            sortedItems = result;
            panelItemSorted.Refresh();
        }