208 references to StyleHelper
PresentationFramework (208)
System\Windows\Annotations\AnnotationHelper.cs (1)
663
host =
StyleHelper
.FindNameInTemplateContent(fdr, "PART_ContentHost", fdr.TemplateInternal) as Decorator;
System\Windows\Condition.cs (1)
216
StyleHelper
.SealIfSealable(_value);
System\Windows\Controls\ContentPresenter.cs (4)
799
StyleHelper
.UpdateTemplateCache(c, (FrameworkTemplate) e.OldValue, (FrameworkTemplate) e.NewValue, TemplateProperty);
872
StyleHelper
.DoTemplateInvalidations(this, oldTemplate);
1009
StyleHelper
.AddCustomTemplateRoot( container, e );
1061
StyleHelper
.AddCustomTemplateRoot(
System\Windows\Controls\Control.cs (1)
439
StyleHelper
.UpdateTemplateCache(c, (FrameworkTemplate) e.OldValue, (FrameworkTemplate) e.NewValue, TemplateProperty);
System\Windows\Controls\ItemsPresenter.cs (1)
142
StyleHelper
.UpdateTemplateCache(ip, (FrameworkTemplate) e.OldValue, (FrameworkTemplate) e.NewValue, TemplateProperty);
System\Windows\Controls\Page.cs (1)
544
StyleHelper
.UpdateTemplateCache(p, (FrameworkTemplate) e.OldValue, (FrameworkTemplate) e.NewValue, TemplateProperty);
System\Windows\Controls\TreeViewItem.cs (1)
824
int index =
StyleHelper
.QueryChildIndexFromChildName(HeaderPartName, template.ChildIndexFromChildName);
System\Windows\Data\BindingOperations.cs (2)
156
Expression expr =
StyleHelper
.GetExpression(target, dp);
273
object o =
StyleHelper
.GetExpression(target, dp);
System\Windows\DataTrigger.cs (2)
151
StyleHelper
.SealIfSealable(_value);
191
return TriggerConditions[0].ConvertAndMatch(
StyleHelper
.GetDataTriggerValue(dataField, container, TriggerConditions[0].Binding));
System\Windows\DependencyPropertyHelper.cs (1)
210
return
StyleHelper
.IsValueDynamic(templatedParent, templateChildIndex, dependencyProperty);
System\Windows\FrameworkContentElement.cs (7)
153
StyleHelper
.UpdateStyleCache(null, fce, (Style) e.OldValue, (Style) e.NewValue, ref fce._styleCache);
227
StyleHelper
.UpdateThemeStyleCache(null, fce, (Style) oldValue, (Style) newValue, ref fce._themeStyleCache);
514
if (
StyleHelper
.GetValueFromStyleOrTemplate(new FrameworkObject(null, this), dp, ref entry))
655
return
StyleHelper
.GetValueFromTemplatedParent(
727
StyleHelper
.OnTriggerSourcePropertyInvalidated(null, frameworkTemplate, TemplatedParent, dp, e, false /*invalidateOnlyContainer*/,
735
StyleHelper
.OnTriggerSourcePropertyInvalidated(Style, null, this, dp, e, true /*invalidateOnlyContainer*/,
745
StyleHelper
.OnTriggerSourcePropertyInvalidated(ThemeStyle, null, this, dp, e, true /*invalidateOnlyContainer*/,
System\Windows\FrameworkElement.cs (17)
175
StyleHelper
.UpdateStyleCache(fe, null, (Style) e.OldValue, (Style) e.NewValue, ref fe._styleCache);
275
StyleHelper
.UpdateThemeStyleCache(fe, null, (Style) oldValue, (Style) newValue, ref fe._themeStyleCache);
351
UncommonField<HybridDictionary[]> dataField =
StyleHelper
.TemplateDataField;
374
StyleHelper
.InvokeDeferredActions(this, template);
812
return
StyleHelper
.FindNameInTemplateContent(this, childName, template) as DependencyObject;
1220
if ((fe != startNode.FE) ||
StyleHelper
.ShouldGetValueFromStyle(dp))
1225
if ((fe != startNode.FE) ||
StyleHelper
.ShouldGetValueFromTemplate(dp))
1230
if ((fe != startNode.FE) ||
StyleHelper
.ShouldGetValueFromThemeStyle(dp))
1256
if ((fce != startNode.FCE) ||
StyleHelper
.ShouldGetValueFromStyle(dp))
1261
if ((fce != startNode.FCE) ||
StyleHelper
.ShouldGetValueFromThemeStyle(dp))
1870
if (
StyleHelper
.GetValueFromStyleOrTemplate(new FrameworkObject(this, null), dp, ref entry))
1940
return
StyleHelper
.GetValueFromTemplatedParent(
2099
StyleHelper
.OnTriggerSourcePropertyInvalidated(null, frameworkTemplate, TemplatedParent, dp, e, false /*invalidateOnlyContainer*/,
2108
StyleHelper
.OnTriggerSourcePropertyInvalidated(Style, null, this, dp, e, true /*invalidateOnlyContainer*/,
2116
StyleHelper
.OnTriggerSourcePropertyInvalidated(null, TemplateInternal, this, dp, e, !HasTemplateGeneratedSubTree /*invalidateOnlyContainer*/,
2123
StyleHelper
.OnTriggerSourcePropertyInvalidated(ThemeStyle, null, this, dp, e, true /*invalidateOnlyContainer*/,
3032
handlers =
StyleHelper
.GetChildRoutedEventHandlers(templateChildIndex, args.RoutedEvent, ref templatedParentTemplate.EventDependents);
System\Windows\FrameworkElementFactory.cs (6)
217
if (
StyleHelper
.IsStylingLogicalTree(dp, value))
589
StyleHelper
.SealIfSealable(propertyValue.ValueInternal);
603
_childIndex =
StyleHelper
.CreateChildIndexFromChildName(_childName, _frameworkTemplate);
698
if (
StyleHelper
.HasResourceDependentsForChild(_childIndex, ref resourceDependents))
719
StyleHelper
.CreateInstanceDataForChild(dataField, container, treeNode, _childIndex,
794
StyleHelper
.InvalidatePropertiesOnTemplateNode(
System\Windows\FrameworkTemplate.cs (20)
310
return
StyleHelper
.FindNameInTemplateContent(templatedParent, name, this);
402
StyleHelper
.SealTemplate(
441
StyleHelper
.SortResourceDependents(ref ResourceDependents);
490
bool visualsCreated =
StyleHelper
.ApplyTemplateContent(templateDataField, container,
771
StyleHelper
.ParentTemplateValuesField.SetValue(dependencyObject, parentTemplateValues);
776
parentTemplateValues =
StyleHelper
.ParentTemplateValuesField.GetValue(dependencyObject);
797
HybridDictionary instanceValues =
StyleHelper
.EnsureInstanceData(
StyleHelper
.TemplateDataField, templatedParent, InstanceStyleData.InstanceValues);
798
StyleHelper
.ProcessInstanceValue(dependencyObject, childIndex, instanceValues, dependencyProperty,
StyleHelper
.UnsharedTemplateContentPropertyIndex, true /*apply*/);
813
HybridDictionary instanceValues =
StyleHelper
.EnsureInstanceData(
StyleHelper
.TemplateDataField, templatedParent, InstanceStyleData.InstanceValues);
814
StyleHelper
.ProcessInstanceValue(dependencyObject, childIndex, instanceValues, dependencyProperty,
StyleHelper
.UnsharedTemplateContentPropertyIndex, true /*apply*/);
855
StyleHelper
.GetInstanceValue(
856
StyleHelper
.TemplateDataField,
862
StyleHelper
.UnsharedTemplateContentPropertyIndex,
1171
if (
StyleHelper
.HasResourceDependentsForChild(templateChildIndex, ref this.ResourceDependents))
1178
StyleHelper
.InvalidatePropertiesOnTemplateNode(container,
1222
childIndex =
StyleHelper
.QueryChildIndexFromChildName(name, childIndexFromChildName);
System\Windows\Generated\FrameworkContentElement.cs (2)
574
FrameworkElementFactory fef =
StyleHelper
.FindFEF(fefRoot, TemplateChildIndex);
621
StyleHelper
.GetThemeStyle(/* fe = */ null, /* fce = */ this);
System\Windows\Generated\FrameworkElement.cs (2)
596
FrameworkElementFactory fef =
StyleHelper
.FindFEF(fefRoot, TemplateChildIndex);
643
StyleHelper
.GetThemeStyle(/* fe = */ this, /* fce = */ null);
System\Windows\MultiDataTrigger.cs (1)
150
retVal = TriggerConditions[i].ConvertAndMatch(
StyleHelper
.GetDataTriggerValue(dataField, container, TriggerConditions[i].Binding));
System\Windows\MultiTrigger.cs (1)
106
(_conditions[i].SourceName != null) ? _conditions[i].SourceName :
StyleHelper
.SelfName);
System\Windows\ResourceDictionary.cs (1)
2330
StyleHelper
.SealIfSealable(value);
System\Windows\Setter.cs (1)
134
StyleHelper
.SealIfSealable(_value);
System\Windows\Style.cs (15)
35
StyleHelper
.RegisterAlternateExpressionStorage();
462
propertyValue.ChildName =
StyleHelper
.SelfName;
558
StyleHelper
.AddEventDependent(0, this.EventHandlersStore, ref EventDependents);
569
StyleHelper
.SortResourceDependents(ref ResourceDependents);
719
StyleHelper
.UpdateTables(ref propertyValue, ref ChildRecordFromChildIndex,
725
StyleHelper
.AddContainerDependent(propertyValue.Property, false /*fromVisualTrigger*/, ref ContainerDependents);
755
if (propertyValue.ChildName !=
StyleHelper
.SelfName)
763
if( conditions[k].SourceName !=
StyleHelper
.SelfName )
771
StyleHelper
.AddContainerDependent(propertyValue.Property, true /*fromVisualTrigger*/, ref this.ContainerDependents);
773
StyleHelper
.UpdateTables(ref propertyValue, ref ChildRecordFromChildIndex,
783
StyleHelper
.AddPropertyTriggerWithAction( trigger, ((Trigger)trigger).Property, ref this.PropertyTriggersWithActions );
792
StyleHelper
.AddPropertyTriggerWithAction( trigger, triggerCondition.Property, ref this.PropertyTriggersWithActions );
797
StyleHelper
.AddDataTriggerWithAction( trigger, ((DataTrigger)trigger).Binding, ref this.DataTriggersWithActions );
806
StyleHelper
.AddDataTriggerWithAction( trigger, dataCondition.Binding, ref this.DataTriggersWithActions );
824
StyleHelper
.ProcessEventTrigger(eventTrigger,
System\Windows\StyleHelper.cs (95)
82
StyleHelper
.DoStyleInvalidations(fe, fce, oldStyle, newStyle);
86
StyleHelper
.ExecuteOnApplyEnterExitActions(fe, fce, newStyle, StyleDataField);
115
if (
StyleHelper
.IsSetOnContainer(FrameworkElement.OverridesDefaultStyleProperty, ref newThemeStyle.ContainerDependents, true))
150
StyleHelper
.DoThemeStyleInvalidations(fe, fce, oldThemeStyle, newThemeStyle, style);
154
StyleHelper
.ExecuteOnApplyEnterExitActions(fe, fce, newThemeStyle, ThemeStyleDataField);
301
if(
StyleHelper
.ShouldGetValueFromStyle(templateProperty)
303
StyleHelper
.ShouldGetValueFromThemeStyle(templateProperty))
307
StyleHelper
.CheckForCyclicReferencesInStyleAndTemplateTriggers(templateProperty, newTemplate, style, themeStyle);
318
StyleHelper
.DoTemplateInvalidations(fe, oldTemplate);
322
StyleHelper
.ExecuteOnApplyEnterExitActions(fe, null, newTemplate);
402
StyleHelper
.ProcessTemplateContentFromFEF(
421
StyleHelper
.ProcessTemplateTriggers(
444
if (
StyleHelper
.IsSetOnContainer(Control.TemplateProperty, ref containerDependents, true) ||
445
StyleHelper
.IsSetOnContainer(ContentPresenter.TemplateProperty, ref containerDependents, true))
452
if (
StyleHelper
.IsSetOnContainer(FrameworkElement.StyleProperty, ref containerDependents, true))
459
if (
StyleHelper
.IsSetOnContainer(FrameworkElement.DefaultStyleKeyProperty, ref containerDependents, true))
466
if (
StyleHelper
.IsSetOnContainer(FrameworkElement.OverridesDefaultStyleProperty, ref containerDependents, true))
473
if (
StyleHelper
.IsSetOnContainer(FrameworkElement.NameProperty, ref containerDependents, true))
868
StyleHelper
.UpdateTables(ref propertyValue, ref childRecordFromChildIndex,
875
StyleHelper
.AddEventDependent(factory._childIndex, factory.EventHandlersStore,
933
conditions[k].SourceChildIndex =
StyleHelper
.QueryChildIndexFromChildName(conditions[k].SourceName, childIndexFromChildID);
942
if (propertyValue.ChildName ==
StyleHelper
.SelfName)
948
StyleHelper
.AddContainerDependent(propertyValue.Property, true /*fromVisualTrigger*/, ref containerDependents);
951
StyleHelper
.UpdateTables(ref propertyValue, ref childRecordFromChildIndex,
961
StyleHelper
.AddPropertyTriggerWithAction( triggerBase, trigger.Property, ref propertyTriggersWithActions );
969
StyleHelper
.AddPropertyTriggerWithAction( triggerBase, triggerCondition.Property, ref propertyTriggersWithActions );
974
StyleHelper
.AddDataTriggerWithAction( triggerBase, dataTrigger.Binding, ref dataTriggersWithActions );
982
StyleHelper
.AddDataTriggerWithAction( triggerBase, dataCondition.Binding, ref dataTriggersWithActions );
993
StyleHelper
.ProcessEventTrigger(eventTrigger,
1088
int childIndex =
StyleHelper
.QueryChildIndexFromChildName(eventTrigger.SourceName, childIndexFromChildName);
1150
childFef =
StyleHelper
.FindFEF(templateRoot, eventTrigger.TriggerChildIndex);
1177
StyleHelper
.AddDelegateToFireTrigger(eventTrigger.RoutedEvent,
1217
StyleHelper
.AddDelegateToFireTrigger(eventTrigger.RoutedEvent,
1246
StyleHelper
.AddEventDependent(0, eventHandlersStore, ref eventDependents);
1248
eventHandlersStore.AddRoutedEventHandler(routedEvent,
StyleHelper
.EventTriggerHandlerOnContainer, false/* HandledEventsToo */);
1259
StyleHelper
.AddEventDependent(childIndex, childFef.EventHandlersStore, ref eventDependents);
1261
childFef.EventHandlersStore.AddRoutedEventHandler(routedEvent,
StyleHelper
.EventTriggerHandlerOnChild, false/* HandledEventsToo */);
1289
StyleHelper
.AddEventDependent( childIndex,
1292
eventHandlersStore.AddRoutedEventHandler(routedEvent,
StyleHelper
.EventTriggerHandlerOnChild, false/* HandledEventsToo */);
1380
StyleHelper
.ProcessInstanceValuesForChild(
1390
StyleHelper
.ProcessInstanceValuesForChild(
1415
StyleHelper
.ProcessInstanceValuesForChild(
1448
StyleHelper
.ProcessInstanceValuesForChild(
1459
StyleHelper
.ProcessInstanceValuesForChild(
2139
templatedChildren =
StyleHelper
.TemplatedFeChildrenField.GetValue(feContainer);
2140
StyleHelper
.TemplatedFeChildrenField.ClearValue(feContainer);
2144
templatedChildren =
StyleHelper
.TemplatedFeChildrenField.GetValue(fceContainer);
2145
StyleHelper
.TemplatedFeChildrenField.ClearValue(fceContainer);
2297
HybridDictionary parentTemplateValues =
StyleHelper
.ParentTemplateValuesField.GetValue(walk);
2299
StyleHelper
.ParentTemplateValuesField.ClearValue(walk);
2310
StyleHelper
.ProcessInstanceValue(walk, childIndex, instanceValues, dp, -1, false /*apply*/);
2672
sourceNode =
StyleHelper
.GetChild(container, sourceChildIndex);
3077
Debug.Assert(!
StyleHelper
.IsSetOnContainer(conditions[j].Property, ref containerDependents, true),
3165
StyleHelper
.UpdateLoadedFlag( container, oldStyle, newStyle );
3170
StyleHelper
.UpdateInstanceData(
3171
StyleHelper
.StyleDataField,
3193
oldStyle != null ? oldStyle.ContainerDependents :
StyleHelper
.EmptyContainerDependents;
3196
newStyle != null ? newStyle.ContainerDependents :
StyleHelper
.EmptyContainerDependents;
3201
StyleHelper
.InvalidateContainerDependents(container,
3247
StyleHelper
.UpdateLoadedFlag( container, oldThemeStyle, newThemeStyle );
3252
StyleHelper
.UpdateInstanceData(
3253
StyleHelper
.ThemeStyleDataField,
3275
oldThemeStyle != null ? oldThemeStyle.ContainerDependents :
StyleHelper
.EmptyContainerDependents;
3278
newThemeStyle != null ? newThemeStyle.ContainerDependents :
StyleHelper
.EmptyContainerDependents;
3286
StyleHelper
.InvalidateContainerDependents(container,
3319
oldTemplateData =
StyleHelper
.TemplateDataField.GetValue(feContainer);
3333
StyleHelper
.UpdateLoadedFlag( container, oldFrameworkTemplate, newFrameworkTemplate );
3344
StyleHelper
.UpdateInstanceData(
3345
StyleHelper
.TemplateDataField,
3385
oldContainerDependents = (oldFrameworkTemplate != null) ? oldFrameworkTemplate.ContainerDependents :
StyleHelper
.EmptyContainerDependents;
3386
newContainerDependents = (newFrameworkTemplate != null) ? newFrameworkTemplate.ContainerDependents :
StyleHelper
.EmptyContainerDependents;
3390
StyleHelper
.ClearGeneratedSubTree(oldTemplateData,
3398
StyleHelper
.InvalidateContainerDependents(container,
3426
StyleHelper
.ClearGeneratedSubTree(oldTemplateData, feContainer /* fe */, null /* fce */,
3464
List<ResourceDictionary> oldStyleTables =
StyleHelper
.GetResourceDictionariesFromStyle(oldStyle);
3465
List<ResourceDictionary> newStyleTables =
StyleHelper
.GetResourceDictionariesFromStyle(newStyle);
3767
object value =
StyleHelper
.GetChildValue(
3768
StyleHelper
.TemplateDataField,
3803
HybridDictionary parentTemplateValues =
StyleHelper
.ParentTemplateValuesField.GetValue(child.DO);
3813
StyleHelper
.GetInstanceValue(
3814
StyleHelper
.TemplateDataField,
3820
StyleHelper
.UnsharedTemplateContentPropertyIndex,
3869
if ((style != null) &&
StyleHelper
.ShouldGetValueFromStyle(dp))
3878
value =
StyleHelper
.GetChildValue(
3879
StyleHelper
.StyleDataField,
3910
if (
StyleHelper
.ShouldGetValueFromTemplate(dp))
3920
value =
StyleHelper
.GetChildValue(
3921
StyleHelper
.TemplateDataField,
3953
if (
StyleHelper
.ShouldGetValueFromThemeStyle(dp))
3965
value =
StyleHelper
.GetChildValue(
3966
StyleHelper
.ThemeStyleDataField,
5356
if (childName ==
StyleHelper
.SelfName)
5391
index =
StyleHelper
.QueryChildIndexFromChildName(childName, frameworkTemplate.ChildIndexFromChildName);
5410
return
StyleHelper
.GetChild(container, index);
5845
this(binding, logicalOp, value,
StyleHelper
.SelfName)
System\Windows\SystemResources.cs (1)
1768
StyleHelper
.SealIfSealable(value);
System\Windows\TemplateContent.cs (9)
276
StyleHelper
.SealIfSealable(value.ValueInternal);
279
StyleHelper
.UpdateTables(ref value, ref OwnerTemplate.ChildRecordFromChildIndex, ref OwnerTemplate.TriggerSourceRecordFromChildIndex,
313
int childIndex =
StyleHelper
.CreateChildIndexFromChildName(name, OwnerTemplate);
1252
StyleHelper
.UpdateTables(ref pv, ref childRecordFromChildIndex,
1273
StyleHelper
.UpdateTables(ref pv, ref childRecordFromChildIndex,
1289
StyleHelper
.UpdateTables(ref pv, ref childRecordFromChildIndex,
1306
StyleHelper
.UpdateTables(ref pv, ref childRecordFromChildIndex,
1345
StyleHelper
.UpdateTables(ref propertyValue,
1364
StyleHelper
.UpdateTables(ref propertyValue,
System\Windows\TemplateNameScope.cs (4)
182
StyleHelper
.CreateInstanceDataForChild(
183
StyleHelper
.TemplateDataField,
215
return
StyleHelper
.FindNameInTemplateContent(fo.FE, name, fo.FE.TemplateInternal);
261
private static UncommonField<Hashtable> _templatedNonFeChildrenField = (UncommonField<Hashtable>)
StyleHelper
.TemplatedNonFeChildrenField;
System\Windows\TreeWalkHelper.cs (7)
782
StyleHelper
.InvalidateResourceDependents(d, info, ref fe.Style.ResourceDependents,
791
StyleHelper
.InvalidateResourceDependents(d, info, ref fe.TemplateInternal.ResourceDependents,
804
StyleHelper
.InvalidateResourceDependentsForChild(
824
StyleHelper
.InvalidateResourceDependents(d, info, ref themeStyle.ResourceDependents,
857
StyleHelper
.InvalidateResourceDependents(d, info, ref fce.Style.ResourceDependents, !
872
StyleHelper
.InvalidateResourceDependentsForChild(
891
StyleHelper
.InvalidateResourceDependents(d, info, ref themeStyle.ResourceDependents,
System\Windows\Trigger.cs (2)
205
StyleHelper
.SealIfSealable(_value);
216
(_sourceName != null) ? _sourceName :
StyleHelper
.SelfName) };
System\Windows\TriggerBase.cs (2)
244
if (source == dependent && propertyValue.ChildName ==
StyleHelper
.SelfName)
286
target =
StyleHelper
.SelfName;