private void GetOrCreateAttachableEvents(XamlSchemaContext schemaContext, List <XamlMember> result, Dictionary <string, List <MethodInfo> > adders)
 {
     foreach (KeyValuePair <string, List <MethodInfo> > pair in adders)
     {
         string     key             = pair.Key;
         XamlMember attachableEvent = null;
         if (!this._attachableMemberCache.TryGetValue(key, out attachableEvent))
         {
             MethodInfo adder = this.PickAttachableEventAdder(pair.Value);
             attachableEvent = schemaContext.GetAttachableEvent(key, adder);
         }
         if (attachableEvent != null)
         {
             result.Add(attachableEvent);
         }
     }
 }
Esempio n. 2
0
 private void GetOrCreateAttachableEvents(XamlSchemaContext schemaContext,
                                          List <XamlMember> result, Dictionary <string, List <MethodInfo> > adders)
 {
     foreach (KeyValuePair <string, List <MethodInfo> > nameAndAdderList in adders)
     {
         string     name   = nameAndAdderList.Key;
         XamlMember member = null;
         if (!_attachableMemberCache.TryGetValue(name, out member))
         {
             MethodInfo adder = PickAttachableEventAdder(nameAndAdderList.Value);
             member = schemaContext.GetAttachableEvent(name, adder);
         }
         if (member != null)
         {
             result.Add(member);
         }
     }
 }