Beispiel #1
0
        private void UpdateCustomSubsetSelector()
        {
            CustomSubsetSelector.Items.Clear();
            var subsets = CustomSubsetFile.GetSubsets(Set);

            foreach (var subset in subsets)
            {
                CustomSubsetSelector.Items.Add(subset);
            }
        }
        public SubsetListScreen(AlgSet set)
        {
            StartPosition = FormStartPosition.CenterScreen;
            InitializeComponent();
            Set = set;
            int startX = 50;
            int startY = 80;
            int currY  = startY;


            File = new CustomSubsetFile("customSubsets.xml");
            var subsets = File.GetSubsets(Set);

            var originalFile = SubsetTools.GetXmlSubsetFile();
            var nameMap      = originalFile.GetNameMap(Set);

            for (int k = 0; k < subsets.Count; k++)
            {
                var control = new SubsetListEntry(subsets[k], File, nameMap)
                {
                    Location = new Point(startX, currY)
                };
                currY += HeightPerRow;
                this.Controls.Add(control);
            }
            this.AutoScroll = true;
        }