247 references to DataGridHelper
PresentationFramework (247)
System\Windows\Controls\DataGrid.cs (26)
606
if (
DataGridHelper
.ShouldNotifyDataGrid(target))
633
if (
DataGridHelper
.ShouldNotifyRowSubtree(target))
644
if (
DataGridHelper
.ShouldNotifyColumnCollection(target) ||
DataGridHelper
.ShouldNotifyColumns(target))
649
if ((
DataGridHelper
.ShouldNotifyColumnHeadersPresenter(target) ||
DataGridHelper
.ShouldNotifyColumnHeaders(target)) && ColumnHeadersPresenter != null)
909
if (!
DataGridHelper
.IsDefaultValue(d, DataGrid.RowStyleProperty))
1021
if (!
DataGridHelper
.IsDefaultValue(d, DataGrid.RowStyleSelectorProperty))
1911
_internalScrollContentPresenter =
DataGridHelper
.FindVisualParent<ScrollContentPresenter>(_internalItemsHost);
1916
_internalScrollContentPresenter =
DataGridHelper
.FindVisualParent<ScrollContentPresenter>(row);
1928
_internalScrollHost =
DataGridHelper
.FindVisualParent<ScrollViewer>(_internalItemsHost);
1933
_internalScrollHost =
DataGridHelper
.FindVisualParent<ScrollViewer>(row);
2299
return ((source == this) || (source == null)) ? CurrentCellContainer :
DataGridHelper
.FindVisualParent<DataGridCell>(source);
3774
if (
DataGridHelper
.IsDefaultValue(this, CanUserAddRowsProperty))
5628
GroupItem currentGroupItem =
DataGridHelper
.FindVisualParent<GroupItem>(currentCellContainer);
5890
DataGridRow focusRow =
DataGridHelper
.FindVisualParent<DataGridRow>(focusContainer);
6189
startingRow =
DataGridHelper
.FindVisualParent<DataGridRow>(startingElement);
6207
targetRowElement =
DataGridHelper
.FindVisualParent<DataGridRow>(targetElement);
6617
row =
DataGridHelper
.FindVisualParent<DataGridRow>(element);
6638
cell =
DataGridHelper
.FindVisualParent<DataGridCell>(element);
7091
if (
DataGridHelper
.IsPropertyTransferEnabled(dataGrid, CanUserSortColumnsProperty) &&
7092
DataGridHelper
.IsDefaultValue(dataGrid, CanUserSortColumnsProperty) &&
7103
DataGridHelper
.TransferProperty(dataGrid, CanUserSortColumnsProperty);
7671
DataGridHelper
.TransferProperty(this, CanUserSortColumnsProperty);
8087
if (!
DataGridHelper
.IsDefaultValue(d, DataGrid.EnableRowVirtualizationProperty))
8522
CellsPanelHorizontalOffset =
DataGridHelper
.GetParentCellsPanelHorizontalOffset(cell);
System\Windows\Controls\DataGridBoundColumn.cs (2)
40
var bindingSortMemberPath =
DataGridHelper
.GetPathFromBinding(column.Binding as Binding);
78
if (
DataGridHelper
.IsOneWay(_binding))
System\Windows\Controls\DataGridCell.cs (25)
135
DataGridHelper
.TransferProperty(this, StyleProperty);
136
DataGridHelper
.TransferProperty(this, IsReadOnlyProperty);
207
DataGridHelper
.TransferProperty(this, StyleProperty);
208
DataGridHelper
.TransferProperty(this, IsReadOnlyProperty);
254
if (
DataGridHelper
.ShouldNotifyCells(target))
258
DataGridHelper
.OnColumnWidthChanged(this, e);
262
DataGridHelper
.TransferProperty(this, StyleProperty);
266
DataGridHelper
.TransferProperty(this, IsReadOnlyProperty);
279
if (
DataGridHelper
.ShouldRefreshCellContent(target))
302
return
DataGridHelper
.GetCoercedTransferPropertyValue(
443
if (
DataGridHelper
.BindingExpressionBelongsToElement<DataGridCell>(bindingExpressionsCopy[i], this))
545
return
DataGridHelper
.GetCoercedTransferPropertyValue(
558
DataGridCell cell =
DataGridHelper
.FindVisualParent<DataGridCell>(e.OriginalSource as UIElement);
571
DataGridCell cell =
DataGridHelper
.FindVisualParent<DataGridCell>(e.OriginalSource as UIElement);
800
bool horizontalLinesVisible =
DataGridHelper
.IsGridLineVisible(dataGridOwner, /*isHorizontal = */ true);
801
bool verticalLinesVisible =
DataGridHelper
.IsGridLineVisible(dataGridOwner, /*isHorizontal = */ false);
808
constraint =
DataGridHelper
.SubtractFromSize(constraint, horizontalLineThickness, /*height = */ true);
813
constraint =
DataGridHelper
.SubtractFromSize(constraint, verticalLineThickness, /*height = */ false);
836
bool horizontalLinesVisible =
DataGridHelper
.IsGridLineVisible(dataGridOwner, /*isHorizontal = */ true);
837
bool verticalLinesVisible =
DataGridHelper
.IsGridLineVisible(dataGridOwner, /*isHorizontal = */ false);
843
arrangeSize =
DataGridHelper
.SubtractFromSize(arrangeSize, horizontalLineThickness, /*height = */ true);
848
arrangeSize =
DataGridHelper
.SubtractFromSize(arrangeSize, verticalLineThickness, /*height = */ false);
871
if (
DataGridHelper
.IsGridLineVisible(dataGrid, /*isHorizontal = */ false))
880
if (
DataGridHelper
.IsGridLineVisible(dataGrid, /*isHorizontal = */ true))
1062
Geometry frozenGeometry =
DataGridHelper
.GetFrozenClipForCell(cell);
System\Windows\Controls\DataGridCellsPanel.cs (2)
981
if (child != null &&
DataGridHelper
.TreeHasFocusAndTabStop(child))
2033
IHierarchicalVirtualizationAndScrollInfo hvsInfo =
DataGridHelper
.FindParent<GroupItem>(parentRowsPresenter) as IHierarchicalVirtualizationAndScrollInfo;
System\Windows\Controls\DataGridColumn.cs (39)
57
return
DataGridHelper
.GetCoercedTransferPropertyValue(
132
return
DataGridHelper
.GetCoercedTransferPropertyValue(
166
return (bool)
DataGridHelper
.GetCoercedTransferPropertyValue(
273
double displayValue =
DataGridHelper
.CoerceToMinMax(changedWidth.DesiredValue, column.MinWidth, column.MaxWidth);
393
DataGridLength width = (DataGridLength)
DataGridHelper
.GetCoercedTransferPropertyValue(
402
newDisplayValue = (double.IsNaN(newDisplayValue) ? newDisplayValue :
DataGridHelper
.CoerceToMinMax(newDisplayValue, column.MinWidth, column.MaxWidth));
421
return
DataGridHelper
.GetCoercedTransferPropertyValue(
435
double transferValue = (double)
DataGridHelper
.GetCoercedTransferPropertyValue(
550
double displayWidth =
DataGridHelper
.CoerceToMinMax(pixelWidth, minWidth, maxWidth);
565
double originalDesiredValue =
DataGridHelper
.CoerceToMinMax(width.DesiredValue, minWidth, maxWidth);
707
DataGridHelper
.UpdateTarget(editingElement);
717
return
DataGridHelper
.ValidateWithoutUpdate(editingElement);
813
if (
DataGridHelper
.ShouldNotifyColumns(target))
821
DataGridHelper
.TransferProperty(this, MaxWidthProperty);
825
DataGridHelper
.TransferProperty(this, MinWidthProperty);
829
DataGridHelper
.TransferProperty(this, WidthProperty);
833
DataGridHelper
.TransferProperty(this, HeaderStyleProperty);
837
DataGridHelper
.TransferProperty(this, CellStyleProperty);
841
DataGridHelper
.TransferProperty(this, IsReadOnlyProperty);
845
DataGridHelper
.TransferProperty(this, DragIndicatorStyleProperty);
853
DataGridHelper
.TransferProperty(this, CanUserSortProperty);
857
DataGridHelper
.TransferProperty(this, CanUserResizeProperty);
861
DataGridHelper
.TransferProperty(this, CanUserReorderProperty);
921
DataGridHelper
.TransferProperty(this, MinWidthProperty);
922
DataGridHelper
.TransferProperty(this, MaxWidthProperty);
923
DataGridHelper
.TransferProperty(this, WidthProperty);
924
DataGridHelper
.TransferProperty(this, HeaderStyleProperty);
925
DataGridHelper
.TransferProperty(this, CellStyleProperty);
926
DataGridHelper
.TransferProperty(this, IsReadOnlyProperty);
927
DataGridHelper
.TransferProperty(this, DragIndicatorStyleProperty);
928
DataGridHelper
.TransferProperty(this, CanUserSortProperty);
929
DataGridHelper
.TransferProperty(this, CanUserReorderProperty);
930
DataGridHelper
.TransferProperty(this, CanUserResizeProperty);
1071
return
DataGridHelper
.GetCoercedTransferPropertyValue(
1087
if (!
DataGridHelper
.IsPropertyTransferEnabled(d, CanUserSortProperty))
1090
DataGridHelper
.TransferProperty(d, CanUserSortProperty);
1322
return
DataGridHelper
.GetCoercedTransferPropertyValue(
1348
return
DataGridHelper
.GetCoercedTransferPropertyValue(
1481
return
DataGridHelper
.GetCoercedTransferPropertyValue(
System\Windows\Controls\DataGridColumnCollection.cs (8)
167
if (
DataGridHelper
.ShouldNotifyColumnCollection(target))
210
if (
DataGridHelper
.ShouldNotifyColumns(target))
281
if (
DataGridHelper
.IsDefaultValue(column, DataGridColumn.DisplayIndexProperty))
516
bool hasDefaultDisplayIndex =
DataGridHelper
.IsDefaultValue(currentColumn, DataGridColumn.DisplayIndexProperty);
658
if (displayIndex == -1 &&
DataGridHelper
.IsDefaultValue(column, DataGridColumn.DisplayIndexProperty))
1194
double displayValue =
DataGridHelper
.CoerceToMinMax(double.IsNaN(width.DesiredValue) ? minWidth : width.DesiredValue, minWidth, column.MaxWidth);
1394
double newDesiredValue =
DataGridHelper
.CoerceToMinMax(width.DesiredValue, changedColumn.MinWidth, changedColumn.MaxWidth);
1934
double columnDisplayWidth =
DataGridHelper
.CoerceToMinMax(width.DisplayValue + widthDelta, column.MinWidth, column.MaxWidth);
System\Windows\Controls\DataGridComboBoxColumn.cs (14)
63
var bindingSortMemberPath =
DataGridHelper
.GetPathFromBinding(column.EffectiveBinding as Binding);
123
if (
DataGridHelper
.IsOneWay(EffectiveBinding))
436
DataGridHelper
.SyncColumnProperty(this, comboBox, ComboBox.SelectedValuePathProperty, SelectedValuePathProperty);
439
DataGridHelper
.SyncColumnProperty(this, comboBox, ComboBox.DisplayMemberPathProperty, DisplayMemberPathProperty);
442
DataGridHelper
.SyncColumnProperty(this, comboBox, ComboBox.ItemsSourceProperty, ItemsSourceProperty);
496
DataGridHelper
.RestoreFlowDirection(comboBox, cell);
511
DataGridHelper
.RestoreFlowDirection(comboBox, cell);
522
DataGridHelper
.SyncColumnProperty(this, comboBox, ComboBox.SelectedValuePathProperty, SelectedValuePathProperty);
523
DataGridHelper
.SyncColumnProperty(this, comboBox, ComboBox.DisplayMemberPathProperty, DisplayMemberPathProperty);
524
DataGridHelper
.SyncColumnProperty(this, comboBox, ComboBox.ItemsSourceProperty, ItemsSourceProperty);
567
DataGridHelper
.CacheFlowDirection(cb.EditableTextBoxSite, cb.Parent as DataGridCell);
568
DataGridHelper
.CacheFlowDirection(cb, cb.Parent as DataGridCell);
584
DataGridHelper
.CacheFlowDirection(cb.EditableTextBoxSite, cb.Parent as DataGridCell);
585
DataGridHelper
.CacheFlowDirection(cb, cb.Parent as DataGridCell);
System\Windows\Controls\DataGridHelper.cs (2)
619
private static readonly DependencyProperty FlowDirectionCacheProperty = DependencyProperty.Register("FlowDirectionCache", typeof(FlowDirection), typeof(
DataGridHelper
));
637
object flowDirectionObj = cell.ReadLocalValue(
DataGridHelper
.FlowDirectionCacheProperty);
System\Windows\Controls\DataGridHyperlinkColumn.cs (6)
186
DataGridHelper
.RestoreFlowDirection(outerBlock, cell);
201
DataGridHelper
.RestoreFlowDirection(textBox, cell);
255
DataGridHelper
.CacheFlowDirection(editingElement, editingElement != null ? editingElement.Parent as DataGridCell : null);
267
DataGridHelper
.CacheFlowDirection(editingElement, editingElement != null ? editingElement.Parent as DataGridCell : null);
282
if (
DataGridHelper
.HasNonEscapeCharacters(e as TextCompositionEventArgs))
286
else if (
DataGridHelper
.IsImeProcessed(e as KeyEventArgs))
System\Windows\Controls\DataGridRow.cs (34)
617
return
DataGridHelper
.GetCoercedTransferPropertyValue(
628
return
DataGridHelper
.GetCoercedTransferPropertyValue(
639
return
DataGridHelper
.GetCoercedTransferPropertyValue(
655
coercedValue =
DataGridHelper
.GetCoercedTransferPropertyValue(
664
coercedValue =
DataGridHelper
.GetCoercedTransferPropertyValue(
680
return
DataGridHelper
.GetCoercedTransferPropertyValue(
691
return
DataGridHelper
.GetCoercedTransferPropertyValue(
702
return
DataGridHelper
.GetCoercedTransferPropertyValue(
713
object visibility =
DataGridHelper
.GetCoercedTransferPropertyValue(
880
if (
DataGridHelper
.ShouldNotifyRows(target))
885
DataGridHelper
.TransferProperty(this, BackgroundProperty);
889
DataGridHelper
.TransferProperty(this, HeaderStyleProperty);
893
DataGridHelper
.TransferProperty(this, HeaderTemplateProperty);
897
DataGridHelper
.TransferProperty(this, HeaderTemplateSelectorProperty);
901
DataGridHelper
.TransferProperty(this, ValidationErrorTemplateProperty);
905
DataGridHelper
.TransferProperty(this, DetailsTemplateProperty);
906
DataGridHelper
.TransferProperty(this, DetailsVisibilityProperty);
910
DataGridHelper
.TransferProperty(this, DetailsTemplateSelectorProperty);
911
DataGridHelper
.TransferProperty(this, DetailsVisibilityProperty);
915
DataGridHelper
.TransferProperty(this, DetailsVisibilityProperty);
938
if (
DataGridHelper
.ShouldNotifyDetailsPresenter(target))
946
if (
DataGridHelper
.ShouldNotifyCellsPresenter(target) ||
947
DataGridHelper
.ShouldNotifyCells(target) ||
948
DataGridHelper
.ShouldRefreshCellContent(target))
957
if (
DataGridHelper
.ShouldNotifyRowHeaders(target) && RowHeader != null)
997
DataGridHelper
.TransferProperty(this, BackgroundProperty);
998
DataGridHelper
.TransferProperty(this, HeaderStyleProperty);
999
DataGridHelper
.TransferProperty(this, HeaderTemplateProperty);
1000
DataGridHelper
.TransferProperty(this, HeaderTemplateSelectorProperty);
1001
DataGridHelper
.TransferProperty(this, ValidationErrorTemplateProperty);
1002
DataGridHelper
.TransferProperty(this, DetailsTemplateProperty);
1003
DataGridHelper
.TransferProperty(this, DetailsTemplateSelectorProperty);
1004
DataGridHelper
.TransferProperty(this, DetailsVisibilityProperty);
1336
return
DataGridHelper
.FindVisualParent<DataGridRow>(element);
System\Windows\Controls\DataGridTextColumn.cs (16)
91
DataGridHelper
.RestoreFlowDirection(textBlock, cell);
108
DataGridHelper
.RestoreFlowDirection(textBox, cell);
115
DataGridHelper
.SyncColumnProperty(this, e, TextElement.FontFamilyProperty, FontFamilyProperty);
116
DataGridHelper
.SyncColumnProperty(this, e, TextElement.FontSizeProperty, FontSizeProperty);
117
DataGridHelper
.SyncColumnProperty(this, e, TextElement.FontStyleProperty, FontStyleProperty);
118
DataGridHelper
.SyncColumnProperty(this, e, TextElement.FontWeightProperty, FontWeightProperty);
119
DataGridHelper
.SyncColumnProperty(this, e, TextElement.ForegroundProperty, ForegroundProperty);
135
DataGridHelper
.SyncColumnProperty(this, textElement, TextElement.FontFamilyProperty, FontFamilyProperty);
138
DataGridHelper
.SyncColumnProperty(this, textElement, TextElement.FontSizeProperty, FontSizeProperty);
141
DataGridHelper
.SyncColumnProperty(this, textElement, TextElement.FontStyleProperty, FontStyleProperty);
144
DataGridHelper
.SyncColumnProperty(this, textElement, TextElement.FontWeightProperty, FontWeightProperty);
147
DataGridHelper
.SyncColumnProperty(this, textElement, TextElement.ForegroundProperty, ForegroundProperty);
222
DataGridHelper
.CacheFlowDirection(editingElement, editingElement != null ? editingElement.Parent as DataGridCell : null);
234
DataGridHelper
.CacheFlowDirection(editingElement, editingElement != null ? editingElement.Parent as DataGridCell : null);
261
if (
DataGridHelper
.HasNonEscapeCharacters(e as TextCompositionEventArgs))
265
else if (
DataGridHelper
.IsImeProcessed(e as KeyEventArgs))
System\Windows\Controls\Primitives\DataGridCellsPresenter.cs (15)
109
DataGridHelper
.TransferProperty(this, HeightProperty);
110
DataGridHelper
.TransferProperty(this, MinHeightProperty);
111
DataGridHelper
.TransferProperty(this, VirtualizingPanel.IsVirtualizingProperty);
201
return
DataGridHelper
.GetCoercedTransferPropertyValue(
212
return
DataGridHelper
.GetCoercedTransferPropertyValue(
384
if (
DataGridHelper
.ShouldNotifyCellsPresenter(target))
413
DataGridHelper
.TransferProperty(this, HeightProperty);
417
DataGridHelper
.TransferProperty(this, MinHeightProperty);
421
DataGridHelper
.TransferProperty(this, VirtualizingPanel.IsVirtualizingProperty);
425
if (
DataGridHelper
.ShouldNotifyCells(target) ||
426
DataGridHelper
.ShouldRefreshCellContent(target))
483
if (
DataGridHelper
.IsGridLineVisible(dataGrid, /*isHorizontal = */ true))
503
DataGridHelper
.TransferProperty(cellsPresenter, VirtualizingPanel.IsVirtualizingProperty);
516
return
DataGridHelper
.GetCoercedTransferPropertyValue(
620
get { return
DataGridHelper
.FindParent<DataGridRow>(this); }
System\Windows\Controls\Primitives\DataGridColumnHeader.cs (20)
113
DataGridHelper
.TransferProperty(this, ContentProperty);
114
DataGridHelper
.TransferProperty(this, ContentTemplateProperty);
115
DataGridHelper
.TransferProperty(this, ContentTemplateSelectorProperty);
116
DataGridHelper
.TransferProperty(this, ContentStringFormatProperty);
117
DataGridHelper
.TransferProperty(this, StyleProperty);
118
DataGridHelper
.TransferProperty(this, HeightProperty);
412
DataGridHelper
.OnColumnWidthChanged(this, e);
416
DataGridHelper
.TransferProperty(this, ContentProperty);
420
DataGridHelper
.TransferProperty(this, ContentTemplateProperty);
424
DataGridHelper
.TransferProperty(this, ContentTemplateSelectorProperty);
428
DataGridHelper
.TransferProperty(this, ContentStringFormatProperty);
432
DataGridHelper
.TransferProperty(this, StyleProperty);
436
DataGridHelper
.TransferProperty(this, HeightProperty);
611
object content =
DataGridHelper
.GetCoercedTransferPropertyValue(
636
return
DataGridHelper
.GetCoercedTransferPropertyValue(
650
return
DataGridHelper
.GetCoercedTransferPropertyValue(
664
return
DataGridHelper
.GetCoercedTransferPropertyValue(
695
return
DataGridHelper
.GetCoercedTransferPropertyValue(
805
return
DataGridHelper
.GetCoercedTransferPropertyValue(
912
Geometry frozenGeometry =
DataGridHelper
.GetFrozenClipForCell(header);
System\Windows\Controls\Primitives\DataGridColumnHeadersPresenter.cs (9)
78
DataGridHelper
.TransferProperty(this, VirtualizingPanel.IsVirtualizingProperty);
83
DataGridHelper
.TransferProperty(fillerColumnHeader, DataGridColumnHeader.StyleProperty);
84
DataGridHelper
.TransferProperty(fillerColumnHeader, DataGridColumnHeader.HeightProperty);
292
if (
DataGridHelper
.ShouldNotifyColumnHeadersPresenter(target))
329
DataGridHelper
.TransferProperty(this, VirtualizingPanel.IsVirtualizingProperty);
333
if (
DataGridHelper
.ShouldNotifyColumnHeaders(target))
377
DataGridHelper
.TransferProperty(headersPresenter, VirtualizingPanel.IsVirtualizingProperty);
390
return
DataGridHelper
.GetCoercedTransferPropertyValue(
1047
_parentDataGrid =
DataGridHelper
.FindParent<DataGrid>(this);
System\Windows\Controls\Primitives\DataGridDetailsPresenter.cs (12)
55
return
DataGridHelper
.GetCoercedTransferPropertyValue(
73
return
DataGridHelper
.GetCoercedTransferPropertyValue(
166
DataGridHelper
.TransferProperty(this, ContentTemplateProperty);
167
DataGridHelper
.TransferProperty(this, ContentTemplateSelectorProperty);
186
DataGridHelper
.TransferProperty(this, ContentTemplateProperty);
190
DataGridHelper
.TransferProperty(this, ContentTemplateSelectorProperty);
224
DataGridHelper
.IsGridLineVisible(dataGrid, /*isHorizontal = */ true))
227
Size desiredSize = base.MeasureOverride(
DataGridHelper
.SubtractFromSize(availableSize, thickness, /*height = */ true));
258
DataGridHelper
.IsGridLineVisible(dataGrid, /*isHorizontal = */ true))
261
Size returnSize = base.ArrangeOverride(
DataGridHelper
.SubtractFromSize(finalSize, thickness, /*height = */ true));
292
DataGridHelper
.IsGridLineVisible(dataGrid, /*isHorizontal = */ true))
328
get { return
DataGridHelper
.FindParent<DataGridRow>(this); }
System\Windows\Controls\Primitives\DataGridRowHeader.cs (16)
236
DataGridHelper
.TransferProperty(this, ContentProperty);
237
DataGridHelper
.TransferProperty(this, StyleProperty);
238
DataGridHelper
.TransferProperty(this, ContentTemplateProperty);
239
DataGridHelper
.TransferProperty(this, ContentTemplateSelectorProperty);
240
DataGridHelper
.TransferProperty(this, WidthProperty);
266
DataGridHelper
.TransferProperty(this, ContentProperty);
270
DataGridHelper
.TransferProperty(this, StyleProperty);
274
DataGridHelper
.TransferProperty(this, ContentTemplateProperty);
278
DataGridHelper
.TransferProperty(this, ContentTemplateSelectorProperty);
282
DataGridHelper
.TransferProperty(this, WidthProperty);
326
return
DataGridHelper
.GetCoercedTransferPropertyValue(
342
return
DataGridHelper
.GetCoercedTransferPropertyValue(
360
return
DataGridHelper
.GetCoercedTransferPropertyValue(
376
return
DataGridHelper
.GetCoercedTransferPropertyValue(
392
return
DataGridHelper
.GetCoercedTransferPropertyValue(
771
return
DataGridHelper
.FindParent<DataGridRow>(this);
System\Windows\Controls\Primitives\SelectiveScrollingGrid.cs (1)
59
ScrollViewer scrollViewer =
DataGridHelper
.FindVisualParent<ScrollViewer>(element);