Пример #1
0
        public Form2(AspectCalc aspectCalc, IEnumerable <List <AspectCalc.Aspect> > result, int step, ImageList.ImageCollection aspectImageList, frmAstip astip)
        {
            _aspectCalc = aspectCalc;
            _asresult   = new List <List <AspectCalc.Aspect> >(result);
            _astip      = astip;
            if (_asresult.Count == 0)
            {
                throw new ArgumentException(Resources.NoResult, nameof(result));
            }

            InitializeComponent();
            for (var i = 0; i < aspectImageList.Count; ++i)
            {
                imageList1.Images.Add(aspectImageList.Keys[i], aspectImageList[i]);
            }

            Text = string.Format(Resources.ResultWindowTitle, _asresult.Count, step);

            foreach (var r in _asresult)
            {
                listBox1.Items.Add(string.Join(" ", r.Select(a => a.FullName)));
            }
        }