Ejemplo n.º 1
0
        public DiscPanel GetLastDiscFromDiscParent(DiscPanel disc)
        {
            var parent    = disc.Parent as ITowerUserControl;
            var lastPanel = parent?.DiscController.GetDiscs().LastOrDefault();

            return(lastPanel);
        }
Ejemplo n.º 2
0
        private void AddDisc(Color color, int order, int weight = 1)
        {
            var disc = new DiscPanel
            {
                Weight    = weight,
                Order     = order,
                BackColor = color
            };

            disc.UpdateDisc(_towerUserControl.ClientRectangle);

            _towerUserControl.Controls.Add(disc);
        }