247 references to DataGridHelper
PresentationFramework (247)
System\Windows\Controls\DataGrid.cs (26)
602
if (
DataGridHelper
.ShouldNotifyDataGrid(target))
626
if (
DataGridHelper
.ShouldNotifyRowSubtree(target))
637
if (
DataGridHelper
.ShouldNotifyColumnCollection(target) ||
DataGridHelper
.ShouldNotifyColumns(target))
642
if ((
DataGridHelper
.ShouldNotifyColumnHeadersPresenter(target) ||
DataGridHelper
.ShouldNotifyColumnHeaders(target)) && ColumnHeadersPresenter != null)
902
if (!
DataGridHelper
.IsDefaultValue(d, DataGrid.RowStyleProperty))
1014
if (!
DataGridHelper
.IsDefaultValue(d, DataGrid.RowStyleSelectorProperty))
1900
_internalScrollContentPresenter =
DataGridHelper
.FindVisualParent<ScrollContentPresenter>(_internalItemsHost);
1905
_internalScrollContentPresenter =
DataGridHelper
.FindVisualParent<ScrollContentPresenter>(row);
1917
_internalScrollHost =
DataGridHelper
.FindVisualParent<ScrollViewer>(_internalItemsHost);
1922
_internalScrollHost =
DataGridHelper
.FindVisualParent<ScrollViewer>(row);
2287
return ((source == this) || (source == null)) ? CurrentCellContainer :
DataGridHelper
.FindVisualParent<DataGridCell>(source);
3747
if (
DataGridHelper
.IsDefaultValue(this, CanUserAddRowsProperty))
5586
GroupItem currentGroupItem =
DataGridHelper
.FindVisualParent<GroupItem>(currentCellContainer);
5848
DataGridRow focusRow =
DataGridHelper
.FindVisualParent<DataGridRow>(focusContainer);
6144
startingRow =
DataGridHelper
.FindVisualParent<DataGridRow>(startingElement);
6162
targetRowElement =
DataGridHelper
.FindVisualParent<DataGridRow>(targetElement);
6572
row =
DataGridHelper
.FindVisualParent<DataGridRow>(element);
6593
cell =
DataGridHelper
.FindVisualParent<DataGridCell>(element);
7047
if (
DataGridHelper
.IsPropertyTransferEnabled(dataGrid, CanUserSortColumnsProperty) &&
7048
DataGridHelper
.IsDefaultValue(dataGrid, CanUserSortColumnsProperty) &&
7059
DataGridHelper
.TransferProperty(dataGrid, CanUserSortColumnsProperty);
7624
DataGridHelper
.TransferProperty(this, CanUserSortColumnsProperty);
8040
if (!
DataGridHelper
.IsDefaultValue(d, DataGrid.EnableRowVirtualizationProperty))
8475
CellsPanelHorizontalOffset =
DataGridHelper
.GetParentCellsPanelHorizontalOffset(cell);
System\Windows\Controls\DataGridBoundColumn.cs (2)
33
var bindingSortMemberPath =
DataGridHelper
.GetPathFromBinding(column.Binding as Binding);
71
if (
DataGridHelper
.IsOneWay(_binding))
System\Windows\Controls\DataGridCell.cs (25)
127
DataGridHelper
.TransferProperty(this, StyleProperty);
128
DataGridHelper
.TransferProperty(this, IsReadOnlyProperty);
196
DataGridHelper
.TransferProperty(this, StyleProperty);
197
DataGridHelper
.TransferProperty(this, IsReadOnlyProperty);
243
if (
DataGridHelper
.ShouldNotifyCells(target))
247
DataGridHelper
.OnColumnWidthChanged(this, e);
251
DataGridHelper
.TransferProperty(this, StyleProperty);
255
DataGridHelper
.TransferProperty(this, IsReadOnlyProperty);
268
if (
DataGridHelper
.ShouldRefreshCellContent(target))
291
return
DataGridHelper
.GetCoercedTransferPropertyValue(
432
if (
DataGridHelper
.BindingExpressionBelongsToElement<DataGridCell>(bindingExpressionsCopy[i], this))
534
return
DataGridHelper
.GetCoercedTransferPropertyValue(
547
DataGridCell cell =
DataGridHelper
.FindVisualParent<DataGridCell>(e.OriginalSource as UIElement);
560
DataGridCell cell =
DataGridHelper
.FindVisualParent<DataGridCell>(e.OriginalSource as UIElement);
780
bool horizontalLinesVisible =
DataGridHelper
.IsGridLineVisible(dataGridOwner, /*isHorizontal = */ true);
781
bool verticalLinesVisible =
DataGridHelper
.IsGridLineVisible(dataGridOwner, /*isHorizontal = */ false);
788
constraint =
DataGridHelper
.SubtractFromSize(constraint, horizontalLineThickness, /*height = */ true);
793
constraint =
DataGridHelper
.SubtractFromSize(constraint, verticalLineThickness, /*height = */ false);
816
bool horizontalLinesVisible =
DataGridHelper
.IsGridLineVisible(dataGridOwner, /*isHorizontal = */ true);
817
bool verticalLinesVisible =
DataGridHelper
.IsGridLineVisible(dataGridOwner, /*isHorizontal = */ false);
823
arrangeSize =
DataGridHelper
.SubtractFromSize(arrangeSize, horizontalLineThickness, /*height = */ true);
828
arrangeSize =
DataGridHelper
.SubtractFromSize(arrangeSize, verticalLineThickness, /*height = */ false);
851
if (
DataGridHelper
.IsGridLineVisible(dataGrid, /*isHorizontal = */ false))
862
if (
DataGridHelper
.IsGridLineVisible(dataGrid, /*isHorizontal = */ true))
1040
Geometry frozenGeometry =
DataGridHelper
.GetFrozenClipForCell(cell);
System\Windows\Controls\DataGridCellsPanel.cs (2)
975
if (child != null &&
DataGridHelper
.TreeHasFocusAndTabStop(child))
2023
IHierarchicalVirtualizationAndScrollInfo hvsInfo =
DataGridHelper
.FindParent<GroupItem>(parentRowsPresenter) as IHierarchicalVirtualizationAndScrollInfo;
System\Windows\Controls\DataGridColumn.cs (39)
53
return
DataGridHelper
.GetCoercedTransferPropertyValue(
128
return
DataGridHelper
.GetCoercedTransferPropertyValue(
162
return (bool)
DataGridHelper
.GetCoercedTransferPropertyValue(
269
double displayValue =
DataGridHelper
.CoerceToMinMax(changedWidth.DesiredValue, column.MinWidth, column.MaxWidth);
389
DataGridLength width = (DataGridLength)
DataGridHelper
.GetCoercedTransferPropertyValue(
398
newDisplayValue = (double.IsNaN(newDisplayValue) ? newDisplayValue :
DataGridHelper
.CoerceToMinMax(newDisplayValue, column.MinWidth, column.MaxWidth));
417
return
DataGridHelper
.GetCoercedTransferPropertyValue(
431
double transferValue = (double)
DataGridHelper
.GetCoercedTransferPropertyValue(
546
double displayWidth =
DataGridHelper
.CoerceToMinMax(pixelWidth, minWidth, maxWidth);
561
double originalDesiredValue =
DataGridHelper
.CoerceToMinMax(width.DesiredValue, minWidth, maxWidth);
703
DataGridHelper
.UpdateTarget(editingElement);
713
return
DataGridHelper
.ValidateWithoutUpdate(editingElement);
809
if (
DataGridHelper
.ShouldNotifyColumns(target))
817
DataGridHelper
.TransferProperty(this, MaxWidthProperty);
821
DataGridHelper
.TransferProperty(this, MinWidthProperty);
825
DataGridHelper
.TransferProperty(this, WidthProperty);
829
DataGridHelper
.TransferProperty(this, HeaderStyleProperty);
833
DataGridHelper
.TransferProperty(this, CellStyleProperty);
837
DataGridHelper
.TransferProperty(this, IsReadOnlyProperty);
841
DataGridHelper
.TransferProperty(this, DragIndicatorStyleProperty);
849
DataGridHelper
.TransferProperty(this, CanUserSortProperty);
853
DataGridHelper
.TransferProperty(this, CanUserResizeProperty);
857
DataGridHelper
.TransferProperty(this, CanUserReorderProperty);
911
DataGridHelper
.TransferProperty(this, MinWidthProperty);
912
DataGridHelper
.TransferProperty(this, MaxWidthProperty);
913
DataGridHelper
.TransferProperty(this, WidthProperty);
914
DataGridHelper
.TransferProperty(this, HeaderStyleProperty);
915
DataGridHelper
.TransferProperty(this, CellStyleProperty);
916
DataGridHelper
.TransferProperty(this, IsReadOnlyProperty);
917
DataGridHelper
.TransferProperty(this, DragIndicatorStyleProperty);
918
DataGridHelper
.TransferProperty(this, CanUserSortProperty);
919
DataGridHelper
.TransferProperty(this, CanUserReorderProperty);
920
DataGridHelper
.TransferProperty(this, CanUserResizeProperty);
1058
return
DataGridHelper
.GetCoercedTransferPropertyValue(
1074
if (!
DataGridHelper
.IsPropertyTransferEnabled(d, CanUserSortProperty))
1077
DataGridHelper
.TransferProperty(d, CanUserSortProperty);
1311
return
DataGridHelper
.GetCoercedTransferPropertyValue(
1337
return
DataGridHelper
.GetCoercedTransferPropertyValue(
1470
return
DataGridHelper
.GetCoercedTransferPropertyValue(
System\Windows\Controls\DataGridColumnCollection.cs (8)
162
if (
DataGridHelper
.ShouldNotifyColumnCollection(target))
205
if (
DataGridHelper
.ShouldNotifyColumns(target))
276
if (
DataGridHelper
.IsDefaultValue(column, DataGridColumn.DisplayIndexProperty))
511
bool hasDefaultDisplayIndex =
DataGridHelper
.IsDefaultValue(currentColumn, DataGridColumn.DisplayIndexProperty);
653
if (displayIndex == -1 &&
DataGridHelper
.IsDefaultValue(column, DataGridColumn.DisplayIndexProperty))
1186
double displayValue =
DataGridHelper
.CoerceToMinMax(double.IsNaN(width.DesiredValue) ? minWidth : width.DesiredValue, minWidth, column.MaxWidth);
1386
double newDesiredValue =
DataGridHelper
.CoerceToMinMax(width.DesiredValue, changedColumn.MinWidth, changedColumn.MaxWidth);
1926
double columnDisplayWidth =
DataGridHelper
.CoerceToMinMax(width.DisplayValue + widthDelta, column.MinWidth, column.MaxWidth);
System\Windows\Controls\DataGridComboBoxColumn.cs (14)
58
var bindingSortMemberPath =
DataGridHelper
.GetPathFromBinding(column.EffectiveBinding as Binding);
118
if (
DataGridHelper
.IsOneWay(EffectiveBinding))
431
DataGridHelper
.SyncColumnProperty(this, comboBox, ComboBox.SelectedValuePathProperty, SelectedValuePathProperty);
434
DataGridHelper
.SyncColumnProperty(this, comboBox, ComboBox.DisplayMemberPathProperty, DisplayMemberPathProperty);
437
DataGridHelper
.SyncColumnProperty(this, comboBox, ComboBox.ItemsSourceProperty, ItemsSourceProperty);
491
DataGridHelper
.RestoreFlowDirection(comboBox, cell);
506
DataGridHelper
.RestoreFlowDirection(comboBox, cell);
517
DataGridHelper
.SyncColumnProperty(this, comboBox, ComboBox.SelectedValuePathProperty, SelectedValuePathProperty);
518
DataGridHelper
.SyncColumnProperty(this, comboBox, ComboBox.DisplayMemberPathProperty, DisplayMemberPathProperty);
519
DataGridHelper
.SyncColumnProperty(this, comboBox, ComboBox.ItemsSourceProperty, ItemsSourceProperty);
562
DataGridHelper
.CacheFlowDirection(cb.EditableTextBoxSite, cb.Parent as DataGridCell);
563
DataGridHelper
.CacheFlowDirection(cb, cb.Parent as DataGridCell);
579
DataGridHelper
.CacheFlowDirection(cb.EditableTextBoxSite, cb.Parent as DataGridCell);
580
DataGridHelper
.CacheFlowDirection(cb, cb.Parent as DataGridCell);
System\Windows\Controls\DataGridHelper.cs (2)
612
private static readonly DependencyProperty FlowDirectionCacheProperty = DependencyProperty.Register("FlowDirectionCache", typeof(FlowDirection), typeof(
DataGridHelper
));
630
object flowDirectionObj = cell.ReadLocalValue(
DataGridHelper
.FlowDirectionCacheProperty);
System\Windows\Controls\DataGridHyperlinkColumn.cs (6)
179
DataGridHelper
.RestoreFlowDirection(outerBlock, cell);
194
DataGridHelper
.RestoreFlowDirection(textBox, cell);
248
DataGridHelper
.CacheFlowDirection(editingElement, editingElement != null ? editingElement.Parent as DataGridCell : null);
260
DataGridHelper
.CacheFlowDirection(editingElement, editingElement != null ? editingElement.Parent as DataGridCell : null);
275
if (
DataGridHelper
.HasNonEscapeCharacters(e as TextCompositionEventArgs))
279
else if (
DataGridHelper
.IsImeProcessed(e as KeyEventArgs))
System\Windows\Controls\DataGridRow.cs (34)
606
return
DataGridHelper
.GetCoercedTransferPropertyValue(
617
return
DataGridHelper
.GetCoercedTransferPropertyValue(
628
return
DataGridHelper
.GetCoercedTransferPropertyValue(
644
coercedValue =
DataGridHelper
.GetCoercedTransferPropertyValue(
653
coercedValue =
DataGridHelper
.GetCoercedTransferPropertyValue(
669
return
DataGridHelper
.GetCoercedTransferPropertyValue(
680
return
DataGridHelper
.GetCoercedTransferPropertyValue(
691
return
DataGridHelper
.GetCoercedTransferPropertyValue(
702
object visibility =
DataGridHelper
.GetCoercedTransferPropertyValue(
865
if (
DataGridHelper
.ShouldNotifyRows(target))
870
DataGridHelper
.TransferProperty(this, BackgroundProperty);
874
DataGridHelper
.TransferProperty(this, HeaderStyleProperty);
878
DataGridHelper
.TransferProperty(this, HeaderTemplateProperty);
882
DataGridHelper
.TransferProperty(this, HeaderTemplateSelectorProperty);
886
DataGridHelper
.TransferProperty(this, ValidationErrorTemplateProperty);
890
DataGridHelper
.TransferProperty(this, DetailsTemplateProperty);
891
DataGridHelper
.TransferProperty(this, DetailsVisibilityProperty);
895
DataGridHelper
.TransferProperty(this, DetailsTemplateSelectorProperty);
896
DataGridHelper
.TransferProperty(this, DetailsVisibilityProperty);
900
DataGridHelper
.TransferProperty(this, DetailsVisibilityProperty);
923
if (
DataGridHelper
.ShouldNotifyDetailsPresenter(target))
928
if (
DataGridHelper
.ShouldNotifyCellsPresenter(target) ||
929
DataGridHelper
.ShouldNotifyCells(target) ||
930
DataGridHelper
.ShouldRefreshCellContent(target))
936
if (
DataGridHelper
.ShouldNotifyRowHeaders(target) && RowHeader != null)
976
DataGridHelper
.TransferProperty(this, BackgroundProperty);
977
DataGridHelper
.TransferProperty(this, HeaderStyleProperty);
978
DataGridHelper
.TransferProperty(this, HeaderTemplateProperty);
979
DataGridHelper
.TransferProperty(this, HeaderTemplateSelectorProperty);
980
DataGridHelper
.TransferProperty(this, ValidationErrorTemplateProperty);
981
DataGridHelper
.TransferProperty(this, DetailsTemplateProperty);
982
DataGridHelper
.TransferProperty(this, DetailsTemplateSelectorProperty);
983
DataGridHelper
.TransferProperty(this, DetailsVisibilityProperty);
1300
return
DataGridHelper
.FindVisualParent<DataGridRow>(element);
System\Windows\Controls\DataGridTextColumn.cs (16)
87
DataGridHelper
.RestoreFlowDirection(textBlock, cell);
104
DataGridHelper
.RestoreFlowDirection(textBox, cell);
111
DataGridHelper
.SyncColumnProperty(this, e, TextElement.FontFamilyProperty, FontFamilyProperty);
112
DataGridHelper
.SyncColumnProperty(this, e, TextElement.FontSizeProperty, FontSizeProperty);
113
DataGridHelper
.SyncColumnProperty(this, e, TextElement.FontStyleProperty, FontStyleProperty);
114
DataGridHelper
.SyncColumnProperty(this, e, TextElement.FontWeightProperty, FontWeightProperty);
115
DataGridHelper
.SyncColumnProperty(this, e, TextElement.ForegroundProperty, ForegroundProperty);
131
DataGridHelper
.SyncColumnProperty(this, textElement, TextElement.FontFamilyProperty, FontFamilyProperty);
134
DataGridHelper
.SyncColumnProperty(this, textElement, TextElement.FontSizeProperty, FontSizeProperty);
137
DataGridHelper
.SyncColumnProperty(this, textElement, TextElement.FontStyleProperty, FontStyleProperty);
140
DataGridHelper
.SyncColumnProperty(this, textElement, TextElement.FontWeightProperty, FontWeightProperty);
143
DataGridHelper
.SyncColumnProperty(this, textElement, TextElement.ForegroundProperty, ForegroundProperty);
218
DataGridHelper
.CacheFlowDirection(editingElement, editingElement != null ? editingElement.Parent as DataGridCell : null);
230
DataGridHelper
.CacheFlowDirection(editingElement, editingElement != null ? editingElement.Parent as DataGridCell : null);
257
if (
DataGridHelper
.HasNonEscapeCharacters(e as TextCompositionEventArgs))
261
else if (
DataGridHelper
.IsImeProcessed(e as KeyEventArgs))
System\Windows\Controls\Primitives\DataGridCellsPresenter.cs (15)
103
DataGridHelper
.TransferProperty(this, HeightProperty);
104
DataGridHelper
.TransferProperty(this, MinHeightProperty);
105
DataGridHelper
.TransferProperty(this, VirtualizingPanel.IsVirtualizingProperty);
195
return
DataGridHelper
.GetCoercedTransferPropertyValue(
206
return
DataGridHelper
.GetCoercedTransferPropertyValue(
375
if (
DataGridHelper
.ShouldNotifyCellsPresenter(target))
404
DataGridHelper
.TransferProperty(this, HeightProperty);
408
DataGridHelper
.TransferProperty(this, MinHeightProperty);
412
DataGridHelper
.TransferProperty(this, VirtualizingPanel.IsVirtualizingProperty);
416
if (
DataGridHelper
.ShouldNotifyCells(target) ||
417
DataGridHelper
.ShouldRefreshCellContent(target))
474
if (
DataGridHelper
.IsGridLineVisible(dataGrid, /*isHorizontal = */ true))
496
DataGridHelper
.TransferProperty(cellsPresenter, VirtualizingPanel.IsVirtualizingProperty);
509
return
DataGridHelper
.GetCoercedTransferPropertyValue(
613
get { return
DataGridHelper
.FindParent<DataGridRow>(this); }
System\Windows\Controls\Primitives\DataGridColumnHeader.cs (20)
107
DataGridHelper
.TransferProperty(this, ContentProperty);
108
DataGridHelper
.TransferProperty(this, ContentTemplateProperty);
109
DataGridHelper
.TransferProperty(this, ContentTemplateSelectorProperty);
110
DataGridHelper
.TransferProperty(this, ContentStringFormatProperty);
111
DataGridHelper
.TransferProperty(this, StyleProperty);
112
DataGridHelper
.TransferProperty(this, HeightProperty);
397
DataGridHelper
.OnColumnWidthChanged(this, e);
401
DataGridHelper
.TransferProperty(this, ContentProperty);
405
DataGridHelper
.TransferProperty(this, ContentTemplateProperty);
409
DataGridHelper
.TransferProperty(this, ContentTemplateSelectorProperty);
413
DataGridHelper
.TransferProperty(this, ContentStringFormatProperty);
417
DataGridHelper
.TransferProperty(this, StyleProperty);
421
DataGridHelper
.TransferProperty(this, HeightProperty);
593
object content =
DataGridHelper
.GetCoercedTransferPropertyValue(
618
return
DataGridHelper
.GetCoercedTransferPropertyValue(
632
return
DataGridHelper
.GetCoercedTransferPropertyValue(
646
return
DataGridHelper
.GetCoercedTransferPropertyValue(
677
return
DataGridHelper
.GetCoercedTransferPropertyValue(
784
return
DataGridHelper
.GetCoercedTransferPropertyValue(
891
Geometry frozenGeometry =
DataGridHelper
.GetFrozenClipForCell(header);
System\Windows\Controls\Primitives\DataGridColumnHeadersPresenter.cs (9)
72
DataGridHelper
.TransferProperty(this, VirtualizingPanel.IsVirtualizingProperty);
77
DataGridHelper
.TransferProperty(fillerColumnHeader, DataGridColumnHeader.StyleProperty);
78
DataGridHelper
.TransferProperty(fillerColumnHeader, DataGridColumnHeader.HeightProperty);
286
if (
DataGridHelper
.ShouldNotifyColumnHeadersPresenter(target))
323
DataGridHelper
.TransferProperty(this, VirtualizingPanel.IsVirtualizingProperty);
327
if (
DataGridHelper
.ShouldNotifyColumnHeaders(target))
365
DataGridHelper
.TransferProperty(headersPresenter, VirtualizingPanel.IsVirtualizingProperty);
378
return
DataGridHelper
.GetCoercedTransferPropertyValue(
1036
_parentDataGrid =
DataGridHelper
.FindParent<DataGrid>(this);
System\Windows\Controls\Primitives\DataGridDetailsPresenter.cs (12)
50
return
DataGridHelper
.GetCoercedTransferPropertyValue(
68
return
DataGridHelper
.GetCoercedTransferPropertyValue(
161
DataGridHelper
.TransferProperty(this, ContentTemplateProperty);
162
DataGridHelper
.TransferProperty(this, ContentTemplateSelectorProperty);
181
DataGridHelper
.TransferProperty(this, ContentTemplateProperty);
185
DataGridHelper
.TransferProperty(this, ContentTemplateSelectorProperty);
219
DataGridHelper
.IsGridLineVisible(dataGrid, /*isHorizontal = */ true))
222
Size desiredSize = base.MeasureOverride(
DataGridHelper
.SubtractFromSize(availableSize, thickness, /*height = */ true));
253
DataGridHelper
.IsGridLineVisible(dataGrid, /*isHorizontal = */ true))
256
Size returnSize = base.ArrangeOverride(
DataGridHelper
.SubtractFromSize(finalSize, thickness, /*height = */ true));
287
DataGridHelper
.IsGridLineVisible(dataGrid, /*isHorizontal = */ true))
325
get { return
DataGridHelper
.FindParent<DataGridRow>(this); }
System\Windows\Controls\Primitives\DataGridRowHeader.cs (16)
230
DataGridHelper
.TransferProperty(this, ContentProperty);
231
DataGridHelper
.TransferProperty(this, StyleProperty);
232
DataGridHelper
.TransferProperty(this, ContentTemplateProperty);
233
DataGridHelper
.TransferProperty(this, ContentTemplateSelectorProperty);
234
DataGridHelper
.TransferProperty(this, WidthProperty);
260
DataGridHelper
.TransferProperty(this, ContentProperty);
264
DataGridHelper
.TransferProperty(this, StyleProperty);
268
DataGridHelper
.TransferProperty(this, ContentTemplateProperty);
272
DataGridHelper
.TransferProperty(this, ContentTemplateSelectorProperty);
276
DataGridHelper
.TransferProperty(this, WidthProperty);
320
return
DataGridHelper
.GetCoercedTransferPropertyValue(
336
return
DataGridHelper
.GetCoercedTransferPropertyValue(
354
return
DataGridHelper
.GetCoercedTransferPropertyValue(
370
return
DataGridHelper
.GetCoercedTransferPropertyValue(
386
return
DataGridHelper
.GetCoercedTransferPropertyValue(
765
return
DataGridHelper
.FindParent<DataGridRow>(this);
System\Windows\Controls\Primitives\SelectiveScrollingGrid.cs (1)
55
ScrollViewer scrollViewer =
DataGridHelper
.FindVisualParent<ScrollViewer>(element);