src\Framework\System\Windows\Markup\BamlRecordReader.cs (134)
486CurrentContext.ElementNameOrPropertyName = contextXamlObjectIds.Name;
487CurrentContext.Uid = contextXamlObjectIds.Uid;
488CurrentContext.Key = dictionaryKey;
524CurrentContext.Key = dictionaryKey;
538data = CurrentContext.ObjectData;
539CurrentContext.ObjectData = null;
643CurrentContext.SetFlag(ReaderFlags.InjectedElement);
663if (CurrentContext.CheckFlag(ReaderFlags.InjectedElement))
665CurrentContext.ClearFlag(ReaderFlags.InjectedElement);
743Debug.Assert(ReaderFlags.DependencyObject == CurrentContext.ContextType);
831Debug.Assert(ReaderFlags.DependencyObject == CurrentContext.ContextType ||
832ReaderFlags.ClrObject == CurrentContext.ContextType ||
833ReaderFlags.PropertyComplexClr == CurrentContext.ContextType ||
834ReaderFlags.PropertyComplexDP == CurrentContext.ContextType);
837if (ReaderFlags.DependencyObject == CurrentContext.ContextType ||
838ReaderFlags.ClrObject == CurrentContext.ContextType ||
839ReaderFlags.PropertyComplexClr == CurrentContext.ContextType ||
840ReaderFlags.PropertyComplexDP == CurrentContext.ContextType)
854if (ReaderFlags.DependencyObject == CurrentContext.ContextType)
1034ReaderContextStackData currentContext = CurrentContext;
1141else if (CurrentContext.CheckFlag(ReaderFlags.IDictionary))
1149CurrentContext.MarkAddedToTree();
1211if (null == CurrentContext ||
1212(ReaderFlags.DependencyObject != CurrentContext.ContextType &&
1213ReaderFlags.ClrObject != CurrentContext.ContextType))
1243Debug.Assert(!CurrentContext.CheckFlag(ReaderFlags.NeedToAddToTree), "Failed to add Element to tree before popping stack");
1245ReaderFlags flags = CurrentContext.ContextFlags;
1255CurrentContext != null)
1257Debug.Assert( CurrentContext.ContextType != ReaderFlags.PropertyComplexClr );
1258Debug.Assert( CurrentContext.ContextType != ReaderFlags.PropertyComplexDP );
1260switch (CurrentContext.ContextType)
1264CurrentContext.ObjectData = currentElement;
1310Debug.Assert(CurrentContext.ContextType == ReaderFlags.ConstructorParams);
1408CurrentContext.ContentProperty = contentProperty;
1440if (CurrentContext.CheckFlag(ReaderFlags.SingletonConstructorParam))
1442param = CurrentContext.ObjectData;
1522paramList = (ArrayList)CurrentContext.ObjectData;
1719ResourceDictionary dictionary = GetDictionaryFromContext(CurrentContext, true /*toInsert*/) as ResourceDictionary;
1977if (null == CurrentContext ||
1978(ReaderFlags.DependencyObject != CurrentContext.ContextType &&
1979ReaderFlags.ClrObject != CurrentContext.ContextType))
2022if (CurrentContext != null)
2026if (CurrentContext.ContentProperty != null)
2028dpOrPi = CurrentContext.ContentProperty;
2029parent = CurrentContext.ObjectData;
2031else if ( (CurrentContext.ContextType == ReaderFlags.PropertyComplexClr)
2032|| (CurrentContext.ContextType == ReaderFlags.PropertyComplexDP) )
2034dpOrPi = CurrentContext.ObjectData;
2078if (null == CurrentContext ||
2079!(ReaderFlags.ClrObject == CurrentContext.ContextType ||
2080ReaderFlags.DependencyObject == CurrentContext.ContextType))
2090ReaderFlags.DependencyObject == CurrentContext.ContextType /*targetIsDependencyObject*/ );
2122CurrentContext.ElementNameOrPropertyName = propertyDefinition.Name;
2226if (null == CurrentContext ||
2227(ReaderFlags.DependencyObject != CurrentContext.ContextType &&
2228ReaderFlags.ClrObject != CurrentContext.ContextType))
2317if (null == CurrentContext ||
2318(ReaderFlags.DependencyObject != CurrentContext.ContextType &&
2319ReaderFlags.ClrObject != CurrentContext.ContextType))
2332if (null == CurrentContext ||
2333(ReaderFlags.DependencyObject != CurrentContext.ContextType &&
2334ReaderFlags.ClrObject != CurrentContext.ContextType))
2348if (null == CurrentContext ||
2349(ReaderFlags.DependencyObject != CurrentContext.ContextType &&
2350ReaderFlags.ClrObject != CurrentContext.ContextType))
2469if (null == CurrentContext ||
2470(ReaderFlags.DependencyObject != CurrentContext.ContextType &&
2471ReaderFlags.ClrObject != CurrentContext.ContextType))
2672if (null == CurrentContext ||
2673(ReaderFlags.DependencyObject != CurrentContext.ContextType &&
2674ReaderFlags.ClrObject != CurrentContext.ContextType))
2725if( CurrentContext.CreateUsingTypeConverter )
2975if( CurrentContext != null )
2977CurrentContext.ElementNameOrPropertyName = name;
3034CurrentContext.ElementNameOrPropertyName = holder.AttributeName;
3049InitPropertyCollection(holder, CurrentContext);
3093holder.Collection = CurrentContext.ObjectData;
3095expectedType = CurrentContext.ObjectData.GetType();
3107CurrentContext.ElementNameOrPropertyName = holder.AttributeName;
3114SetCollectionPropertyValue(CurrentContext);
3131CurrentContext.ElementNameOrPropertyName = holder.AttributeName;
3138SetCollectionPropertyValue(CurrentContext);
3334SetKeyOnContext(key, bamlDefAttributeRecord.Value, CurrentContext, ParentContext);
3345if( CurrentContext == null )
3348CurrentContext.Uid = bamlDefAttributeRecord.Value;
3355UIElement element = CurrentContext.ObjectData as UIElement;
3406SetKeyOnContext(keyType, XamlReaderHelper.DefinitionName, CurrentContext, ParentContext);
3461if (null == CurrentContext)
3486switch (CurrentContext.ContextType)
3492if (CurrentContext.CreateUsingTypeConverter)
3494Debug.Assert( CurrentContext.ObjectData == null && CurrentContext.ExpectedType != null,
3498object o = GetObjectFromString(CurrentContext.ExpectedType, bamlTextRecord.Value, converterTypeId);
3501CurrentContext.ObjectData = o;
3502CurrentContext.ExpectedType = null;
3507CurrentContext.ExpectedType.FullName);
3519ThrowException(SRID.ParserCantCreateInstanceType, CurrentContext.ExpectedType.FullName);
3524IAddChild iacParent = GetIAddChildFromContext(CurrentContext);
3529else if (CurrentContext.ContentProperty != null)
3531AddToContentProperty(parent, CurrentContext.ContentProperty, bamlTextRecord.Value);
3547if (null == CurrentContext.ExpectedType)
3550GetPropNameFrom(CurrentContext.ObjectData));
3557BamlAttributeInfoRecord attribInfo = CurrentContext.ObjectData as BamlAttributeInfoRecord;
3580if (null == CurrentContext.ExpectedType)
3583GetPropNameFrom(CurrentContext.ObjectData));
3587object o = GetObjectFromString(CurrentContext.ExpectedType, bamlTextRecord.Value, converterTypeId);
3596CurrentContext.ExpectedType.FullName, bamlTextRecord.Value);
3604BamlCollectionHolder holder = GetCollectionHolderFromContext(CurrentContext, true);
3618BamlCollectionHolder holder = GetCollectionHolderFromContext(CurrentContext, true);
3679Debug.Assert(null != CurrentContext &&
3680ReaderFlags.PropertyComplexDP == CurrentContext.ContextType &&
3681null != CurrentContext.ExpectedType && null != ParentContext);
3789CurrentContext.ExpectedType = null;
3886Debug.Assert(null != CurrentContext &&
3887ReaderFlags.PropertyComplexClr == CurrentContext.ContextType &&
3888null != CurrentContext.ExpectedType);
3929CurrentContext.ExpectedType = null;
3936Debug.Assert(null != CurrentContext &&
3937ReaderFlags.ConstructorParams == CurrentContext.ContextType);
3947if (CurrentContext.ObjectData == null)
3949CurrentContext.ObjectData = o;
3950CurrentContext.SetFlag(ReaderFlags.SingletonConstructorParam);
3952else if (CurrentContext.CheckFlag(ReaderFlags.SingletonConstructorParam))
3955paramList.Add(CurrentContext.ObjectData);
3957CurrentContext.ObjectData = paramList;
3958CurrentContext.ClearFlag(ReaderFlags.SingletonConstructorParam);
3962ArrayList paramList = (ArrayList) CurrentContext.ObjectData;
3974DependencyObject e = CurrentContext.ObjectData as DependencyObject;
4317return GetObjectDataFromContext(CurrentContext);
4493if (CurrentContext == null)
4602CurrentContext.ObjectData = element;
4631ReaderContextStackData currentContext = CurrentContext;
4888CurrentContext.ObjectData = element;
4911ReaderContextStackData currentContext = CurrentContext;