示例#1
0
 private void ClientPluginUnloading(PluginEventArgs e)
 {
     var pluginViewModel = Plugins.FirstOrDefault(pvm => pvm.PluginName == e.PluginName);
       if (pluginViewModel != null)
       {
     Plugins.Remove(pluginViewModel);
     pluginViewModel.Dispose();
       }
 }
示例#2
0
 private void ClientPluginUnloading(object sender, PluginEventArgs e)
 {
   Dispatcher.BeginInvoke(new Action<PluginEventArgs>(args =>
   {
     var pluginViewModel = Plugins.FirstOrDefault(pvm => pvm.PluginName == e.PluginName);
     if (pluginViewModel != null)
     {
       Plugins.Remove(pluginViewModel);
       pluginViewModel.Dispose();
     }
   }), e);
 }
示例#3
0
 private void ClientPluginLoaded(PluginEventArgs e)
 {
     Plugins.Add(new PluginViewModel(e.PluginName));
 }
示例#4
0
 private void ClientPluginLoaded(object sender, PluginEventArgs e)
 {
   Dispatcher.BeginInvoke(new Action<PluginEventArgs>(args =>
   {
     Plugins.Add(new PluginViewModel(args.PluginName));
   }), e);
 }