Пример #1
0
 public static void AddHandler(IActionProvider provider, ActionEventHandler handler)
 {
     ActionDispatcher dispatcher;
     if (map.ContainsKey(provider))
     {
         dispatcher = map[provider];
     }
     else
     {
         dispatcher = new ActionDispatcher(provider);
         map.Add(provider, dispatcher);
     }
     dispatcher.ActionEvent += handler;
 }