protected override FrameworkElement GenerateElement(DataGridCell cell, object dataItem) { IconCellControl tb = null; tb = new IconCellControl(cell, true); if (this.Binding != null) { //tb.RightTextBlock.SetBinding(TextBlock.TextProperty, this.Binding); //tb.RightTextBlock.TextWrapping = TextWrapping.Wrap; tb.SetBinding(IconCellControl.HiddenProperty, this.Binding); } return(tb); }
private static void OnHiddenPropertyChanged(DependencyObject d, DependencyPropertyChangedEventArgs e) { IconCellControl cell = d as IconCellControl; cell.OnHiddenChanged(); }
protected override FrameworkElement GenerateElement(DataGridCell cell, object dataItem) { IconCellControl tb = null; tb = new IconCellControl(cell, true); if (this.Binding != null) { //tb.RightTextBlock.SetBinding(TextBlock.TextProperty, this.Binding); //tb.RightTextBlock.TextWrapping = TextWrapping.Wrap; tb.SetBinding(IconCellControl.HiddenProperty, this.Binding); } return tb; }