예제 #1
0
 public void InsertEventGlobal(string className, CNamedEvent pEvent)
 {
     if (this.FindEventStatic(className, pEvent.GetName()) == null)
     {
         if (!this.ms_eventInfosGlobal.ContainsKey(className))
         {
             this.ms_eventInfosGlobal.Add(className, new DictionaryView <CStringID, CNamedEvent>());
         }
         DictionaryView <CStringID, CNamedEvent> dictionaryView = this.ms_eventInfosGlobal.get_Item(className);
         CNamedEvent cNamedEvent = (CNamedEvent)pEvent.clone();
         CStringID   cStringID   = new CStringID(cNamedEvent.GetName());
         dictionaryView.Add(cStringID, cNamedEvent);
     }
 }
예제 #2
0
 public void InsertEventGlobal(string className, CNamedEvent pEvent)
 {
     if (this.FindEventStatic(className, pEvent.GetName()) == null)
     {
         if (!this.ms_eventInfosGlobal.ContainsKey(className))
         {
             this.ms_eventInfosGlobal.Add(className, new DictionaryView <CStringID, CNamedEvent>());
         }
         DictionaryView <CStringID, CNamedEvent> view = this.ms_eventInfosGlobal[className];
         CNamedEvent event3 = (CNamedEvent)pEvent.clone();
         CStringID   key    = new CStringID(event3.GetName());
         view.Add(key, event3);
     }
 }
예제 #3
0
        public void InsertEventGlobal(string className, CNamedEvent pEvent)
        {
            CNamedEvent toFind = FindEventStatic(className, pEvent.GetName());

            if (toFind == null)
            {
                if (!ms_eventInfosGlobal.ContainsKey(className))
                {
                    ms_eventInfosGlobal.Add(className, new Dictionary <CStringID, CNamedEvent>());
                }

                Dictionary <CStringID, CNamedEvent> events = ms_eventInfosGlobal[className];

                CNamedEvent e       = (CNamedEvent)pEvent.clone();
                CStringID   eventId = new CStringID(e.GetName());
                events.Add(eventId, e);
            }
        }