2 writes to _context
PresentationFramework (2)
System\Windows\Markup\Baml2006\Baml2006Reader.cs (2)
113_context = new Baml2006ReaderContext(schemaContext); 219_context = null;
165 references to _context
PresentationFramework (165)
System\Windows\Markup\Baml2006\Baml2006Reader.cs (165)
130_context.TemplateStartDepth = -1; 230get { return _context.CurrentFrame != null; } 235get { return _context.LineNumber; } 240get { return _context.LineOffset; } 249_context.KeyList = new List<KeyRecord>(); 250_context.CurrentFrame.IsDeferredContent = true; 320foreach (KeyRecord keyRecord in _context.KeyList) 330return _context.KeyList; 344_context.CurrentKey = _context.KeyList.IndexOf(record); 371Baml2006ReaderFrame baseFrame = _context.CurrentFrame; 374while (baseFrame != _context.CurrentFrame) 386_context.CurrentKey = _context.KeyList.IndexOf(record); 709string name = _context.SchemaContext.GetString(_binaryReader.ReadInt16()); 711if (_context.TemplateStartDepth < 0) 733bool shouldInjectContentProperty = _context.CurrentFrame.Member == null; 737if (_context.CurrentFrame.XamlType.ContentProperty != null) 741_xamlNodesWriter.WriteStartMember(_context.CurrentFrame.XamlType.ContentProperty); 779bool shouldDropProperty = _context.CurrentFrame.Member == null; 803_context.InsideStaticResource = false; 806_context.PopScope(); 815_context.LastKey.StaticResources.Add(staticResource); 816_context.InsideStaticResource = true; 821_context.PushScope(); 822_context.CurrentFrame.XamlType = type; 827InjectPropertyAndFrameIfNeeded(_context.SchemaContext.GetXamlType(typeof(StaticResourceExtension)), 0); 830object value = _context.KeyList[_context.CurrentKey - 1].StaticResources[resourceId]; 897optimizedStaticResource.KeyValue = _context.SchemaContext.GetString(keyId); 901var staticResources = _context.LastKey.StaticResources; 934_context.KeyList = new List<KeyRecord>(); 935_context.CurrentKey = 0; 936_context.CurrentFrame.IsDeferredContent = true; 950_context.CurrentFrame.Key = new KeyRecord(false, false, 0, value); 969string value = _context.SchemaContext.GetString(keyStringId); 972if (_context.CurrentFrame.IsDeferredContent) 974_context.KeyList.Add(key); 978_context.CurrentFrame.Key = key; 996if (_context.CurrentFrame.IsDeferredContent) 998_context.KeyList.Add(key); 1002_context.CurrentFrame.Key = key; 1037if (!_context.InsideKeyRecord && !_context.InsideStaticResource) 1039InjectPropertyAndFrameIfNeeded(_context.SchemaContext.GetXamlType(typeof(String)), 0); 1047_context.CurrentFrame.Member != XamlLanguage.PositionalParameters) 1049if (_context.CurrentFrame.XamlType != null && _context.CurrentFrame.XamlType.IsCollection) 1051if (!_context.CurrentFrame.XamlType.IsWhitespaceSignificantCollection) 1058if (_context.CurrentFrame.Member.Type != null && 1059!_context.CurrentFrame.Member.Type.UnderlyingType.IsAssignableFrom(typeof(String))) 1070_context.CurrentFrame.Member = null; 1078_context.CurrentFrame.Member = XamlLanguage.PositionalParameters; 1130if (_root != null && _context.CurrentFrame.Depth == 0) 1148_context.PushScope(); 1149_context.CurrentFrame.XamlType = type; 1188_xamlNodesWriter.WriteStartObject(_context.CurrentFrame.XamlType); 1192if (_context.CurrentFrame.Depth == 1) 1203if (_context.PreviousFrame.IsDeferredContent && !_context.InsideStaticResource) 1211KeyRecord record = _context.KeyList[_context.CurrentKey]; 1234_context.CurrentKey++; 1242if (_context.CurrentFrame.Key != null) 1246KeyRecord keyRecord = _context.CurrentFrame.Key; 1273_context.CurrentFrame.Key = null; 1276if (_context.CurrentFrame.DelayedConnectionId != -1) 1281_xamlNodesWriter.WriteValue(_context.CurrentFrame.DelayedConnectionId); 1285_xamlNodesWriter.WriteValue(_context.CurrentFrame.DelayedConnectionId.ToString(System.Windows.Markup.TypeConverterHelper.InvariantEnglishUS)); 1292if (_context.CurrentFrame.IsDeferredContent) 1294_context.KeyList = null; 1296_context.PopScope(); 1307XamlType type = _context.SchemaContext.GetXamlType(typeId); 1309_context.PushScope(); 1310_context.CurrentFrame.XamlType = type; 1314KeyRecord key = new KeyRecord(isShared, isSharedSet, valuePosition, _context.SchemaContext) 1321_context.InsideKeyRecord = true; 1328if (_context.PreviousFrame.IsDeferredContent) 1330_context.KeyList.Add(key); 1334_context.PreviousFrame.Key = key; 1342if (_context.PreviousFrame.IsDeferredContent) 1344key = _context.LastKey; 1348key = _context.PreviousFrame.Key; 1356_context.InsideKeyRecord = false; 1358_context.PopScope(); 1369if (_context.CurrentFrame.XamlType.UnderlyingType == typeof(EventSetter)) 1372_xamlNodesWriter.WriteStartMember(_context.SchemaContext.EventSetterEventProperty); 1389_xamlNodesWriter.WriteStartMember(_context.SchemaContext.EventSetterHandlerProperty); 1395XamlMember property = GetProperty(_binaryReader.ReadInt16(), _context.CurrentFrame.XamlType); 1404if (_context.InsideKeyRecord || _context.InsideStaticResource) 1412if (_context.CurrentFrame.XamlType == null) 1418if (_context.CurrentFrame.Member != null) 1420throw new XamlParseException(SR.Format(SR.PropertyOutOfOrder, _context.CurrentFrame.Member)); 1495XamlMember property = GetProperty(_binaryReader.ReadInt16(), _context.CurrentFrame.XamlType); 1512serializerTypeId, property, _context.CurrentFrame.XamlType)); 1528converter = new EnumConverter(_context.CurrentFrame.XamlType.UnderlyingType); 1574XamlMember property = GetProperty(_binaryReader.ReadInt16(), _context.CurrentFrame.XamlType); 1636XamlMember property = GetProperty(propertyId, _context.CurrentFrame.XamlType); 1687param = _context.SchemaContext.GetDependencyProperty(valueId); 1853XamlMember property = GetProperty(_binaryReader.ReadInt16(), _context.CurrentFrame.XamlType); 1883XamlMember property = _context.SchemaContext.GetProperty(propertyId, _context.CurrentFrame.XamlType); 1891Object resource = _context.KeyList[_context.CurrentKey - 1].StaticResources[resourceId]; 1953string text = _context.SchemaContext.GetString(optimizedResource.KeyId); 1973XamlMember property = GetProperty(_binaryReader.ReadInt16(), _context.CurrentFrame.XamlType); 1975_context.CurrentFrame.Member = property; 1984XamlMember property = GetProperty(_binaryReader.ReadInt16(), _context.CurrentFrame.XamlType); 1986_context.CurrentFrame.Member = property; 1994XamlMember property = GetProperty(_binaryReader.ReadInt16(), _context.CurrentFrame.XamlType); 1996_context.CurrentFrame.Member = property; 2004_context.CurrentFrame.Member = null; 2012if (_lookingForAKeyOnAMarkupExtensionInADictionaryDepth == _context.CurrentFrame.Depth) 2019_context.CurrentFrame.Member = null; 2031Baml2006ReaderFrame currentFrame = _context.CurrentFrame; 2113Debug.Assert(_context.CurrentFrame.XamlType != null, "BAML Xmlns record is only legal between ElementStart and ElementEnd"); 2121_context.CurrentFrame.AddNamespace(prefix, xamlNs); 2151_context.LineOffset = _binaryReader.ReadInt32(); 2154consumer?.SetLineInfo(_context.LineNumber, _context.LineOffset); 2160_context.LineNumber = _binaryReader.ReadInt32(); 2161_context.LineOffset = _binaryReader.ReadInt32(); 2164consumer?.SetLineInfo(_context.LineNumber, _context.LineOffset); 2242_context.CurrentFrame.ContentProperty = contentProperty; 2250if (_context.CurrentFrame.Member != null) 2255Baml2006ReaderFrame frame = _context.CurrentFrame; 2258frame = _context.PreviousFrame; 2312if (_context.CurrentFrame.Flags == Baml2006ReaderFrameFlags.IsImplict) 2317_context.PopScope(); 2320if (_context.CurrentFrame.Flags == Baml2006ReaderFrameFlags.HasImplicitProperty) 2323if (_context.CurrentFrame.Depth == _context.TemplateStartDepth) 2331_context.TemplateStartDepth = -1; 2336_context.CurrentFrame.Member = null; 2337_context.CurrentFrame.Flags = Baml2006ReaderFrameFlags.None; 2345if (_lookingForAKeyOnAMarkupExtensionInADictionaryDepth == _context.CurrentFrame.Depth) 2350XamlType parentType = _context.CurrentFrame.XamlType; 2351XamlMember parentProperty = _context.CurrentFrame.Member; 2359if (_context.CurrentFrame.ContentProperty != null) 2361_context.CurrentFrame.Member = parentProperty = _context.CurrentFrame.ContentProperty; 2365_context.CurrentFrame.Member = parentProperty = parentType.ContentProperty; 2371_context.CurrentFrame.Member = parentProperty = XamlLanguage.Items; 2375_context.CurrentFrame.Member = parentProperty = XamlLanguage.Initialization; 2382_context.CurrentFrame.Flags = Baml2006ReaderFrameFlags.HasImplicitProperty; 2386if (_context.TemplateStartDepth < 0 && _isBinaryProvider) 2391_context.TemplateStartDepth = _context.CurrentFrame.Depth; 2403consumer?.SetLineInfo(_context.LineNumber, _context.LineOffset); 2431else if (_context.CurrentFrame.Flags == Baml2006ReaderFrameFlags.HasImplicitProperty) 2459_lookingForAKeyOnAMarkupExtensionInADictionaryDepth = _context.CurrentFrame.Depth; 2474EmitGoItemsPreamble(_context.CurrentFrame.Member.Type); 2485_context.PushScope(); 2486_context.CurrentFrame.XamlType = parentPropertyType; 2488_context.CurrentFrame.Flags = Baml2006ReaderFrameFlags.IsImplict; 2490_context.CurrentFrame.Member = XamlLanguage.Items; 2491_xamlNodesWriter.WriteStartMember(_context.CurrentFrame.Member); 2496return _context.LastKey.LastStaticResource; 2641XamlType type = _context.SchemaContext.GetXamlType(System.Windows.Markup.SystemKeyConverter.GetSystemClassType(keyId)); 2713get { return _context.CurrentFrame.FreezeFreezables; } 2714set { _context.CurrentFrame.FreezeFreezables = value; } 2722get { return _context.CurrentFrame.FreezeFreezables; }