protected override void SetUpContentView() { base.SetUpContentView(); if (CustomCell.ShowArrowIndicator) { Accessory = UITableViewCellAccessory.DisclosureIndicator; EditingAccessory = UITableViewCellAccessory.DisclosureIndicator; SetRightMarginZero(); } StackV.RemoveArrangedSubview(ContentStack); StackV.RemoveArrangedSubview(DescriptionLabel); ContentStack.RemoveFromSuperview(); DescriptionLabel.RemoveFromSuperview(); _coreView = new CustomCellContent(); if (CustomCell.UseFullSize) { StackH.RemoveArrangedSubview(IconView); IconView.RemoveFromSuperview(); StackH.LayoutMargins = new UIEdgeInsets(0, 0, 0, 0); StackH.Spacing = 0; } StackV.AddArrangedSubview(_coreView); }
/// <summary> /// Dispose the specified disposing. /// </summary> /// <returns>The dispose.</returns> /// <param name="disposing">If set to <c>true</c> disposing.</param> protected override void Dispose(bool disposing) { if (disposing) { if (_command != null) { _command.CanExecuteChanged -= Command_CanExecuteChanged; } Execute = null; _command = null; _colorCache.Clear(); _colorCache = null; _coreView?.RemoveFromSuperview(); _coreView?.Dispose(); _coreView = null; } base.Dispose(disposing); }