Beispiel #1
0
        /// <summary>
        /// Prepares the Column element based on the Visible column
        /// </summary>
        /// <remarks></remarks>
        protected override FrameworkElement OnInitializeColumnElement(object dataContext, bool isInEdit)
        {
            UIElement element = null;

            if (IsIndentColumn)
            {
                element = new GridIndentCell();
            }
            else
            {
                this.IsEditing = isInEdit;
                element        = this.Renderer.PrepareUIElements(this, dataContext, this.IsEditing);
            }
            this.SetBindings(element);
            return((FrameworkElement)element);
        }
        /// <summary>
        /// Prepares the Column element based on the Visible column
        /// </summary>
        /// <remarks></remarks>
        protected override FrameworkElement OnInitializeColumnElement(object dataContext, bool isInEdit)
        {
            UIElement element = null;

            if (IsIndentColumn)
            {
                element = new GridIndentCell();
            }
            else
            {
                this.IsEditing = isInEdit;
                element        = this.Renderer.PrepareUIElements(this, dataContext, this.IsEditing);
                if (element is GridGroupSummaryCell)
                {
                    (element as GridGroupSummaryCell).ColumnBase = this;
                }
                else if (element is GridCaptionSummaryCell)
                {
                    (element as GridCaptionSummaryCell).ColumnBase = this;
                }
            }
            this.SetBindings(element);
            return((FrameworkElement)element);
        }