Example #1
0
        private void panelHolst_MouseUp(object sender, MouseEventArgs e)
        {
            pointEnd.X = MousePosition.X - this.Location.X - panelHolst.Location.X - 4;
            pointEnd.Y = MousePosition.Y - this.Location.Y - panelHolst.Location.Y - 19;

            ConstructorInfo inf      = currentFigure.GetConstructor(new Type[] { });
            var             instance = (Figure)inf.Invoke(new object[] { });

            instance.pointBegin = pointBegin;
            instance.pointEnd   = pointEnd;
            figlst.addToList(instance);
            figlst.DrawList();
        }