Пример #1
0
        protected override void Dispose(bool disposing)
        {
            if (disposing)
            {
                if (CellBase != null)
                {
                    CellBase.PropertyChanged -= CellPropertyChanged;
                    if (CellParent != null)
                    {
                        CellParent.PropertyChanged -= ParentPropertyChanged;
                    }

                    if (CellBase.Section != null)
                    {
                        CellBase.Section.PropertyChanged -= SectionPropertyChanged;
                        CellBase.Section = null;
                    }
                }

                BackgroundColor.Dispose();
                SelectedColor.Dispose();
                Ripple.Dispose();

                Background?.Dispose();
                Background = null;
            }

            base.Dispose(disposing);
        }
        protected override void Dispose(bool disposing)
        {
            base.Dispose(disposing);
            if (disposing)
            {
                SelectedColor?.Dispose();
                SelectedColor = null;

                StartingColor?.Dispose();
                StartingColor = null;

                ColorPicked = null;
            }
        }