Ejemplo n.º 1
0
        /// <summary>Clears the container reference for the specified cell.</summary>
        /// <param name="element">The <see cref="T:System.Windows.Controls.DataGridCell" /> to clear.</param>
        /// <param name="item">The data item. This value is not used.</param>
        // Token: 0x06005C9B RID: 23707 RVA: 0x001A0DA8 File Offset: 0x0019EFA8
        protected override void ClearContainerForItemOverride(DependencyObject element, object item)
        {
            DataGridCell dataGridCell     = (DataGridCell)element;
            DataGridRow  dataGridRowOwner = this.DataGridRowOwner;

            if (dataGridCell.RowOwner == dataGridRowOwner)
            {
                dataGridCell.Tracker.StopTracking(ref this._cellTrackingRoot);
            }
            dataGridCell.ClearCell(dataGridRowOwner);
        }
        /// <summary>
        ///     Clears a container of references.
        /// </summary>
        /// <param name="element">The container being cleared.</param>
        /// <param name="item">The data item that the container represented.</param>
        protected override void ClearContainerForItemOverride(DependencyObject element, object item)
        {
            DataGridCell cell     = (DataGridCell)element;
            DataGridRow  rowOwner = DataGridRowOwner;

            if (cell.RowOwner == rowOwner)
            {
                cell.Tracker.StopTracking(ref _cellTrackingRoot);
            }

            cell.ClearCell(rowOwner);
        }