@Override
    public void actionPerformed(@NotNull AnActionEvent e) {
      Map<C, IdeaPluginDescriptorImpl> selection = getSelection();
      ApplicationInfoEx applicationInfo = ApplicationInfoEx.getInstanceEx();
      Map<PluginId, IdeaPluginDescriptorImpl> plugins = PluginManagerCore.INSTANCE.buildPluginIdMap();

      List<IdeaPluginDescriptorImpl> toDeleteWithAsk = new ArrayList<>();
      List<IdeaPluginDescriptorImpl> toDelete = new ArrayList<>();

      for (Map.Entry<C, IdeaPluginDescriptorImpl> entry : selection.entrySet()) {
        IdeaPluginDescriptorImpl descriptor = entry.getValue();
        List<IdeaPluginDescriptorImpl> dependents = MyPluginModel.getDependents(descriptor, applicationInfo, plugins);
        if (dependents.isEmpty()) {
          toDeleteWithAsk.add(descriptor);
        }
        else {
          boolean bundledUpdate = MyPluginModel.isBundledUpdate(descriptor);
          if (askToUninstall(getUninstallDependentsMessage(descriptor, dependents, bundledUpdate), entry.getKey(), bundledUpdate)) {
            toDelete.add(descriptor);
          }
        }
      }

      boolean runFinishAction = false;

      if (!toDeleteWithAsk.isEmpty()) {
        boolean bundledUpdate = toDeleteWithAsk.size() == 1 && MyPluginModel.isBundledUpdate(toDeleteWithAsk.get(0));
        if (askToUninstall(getUninstallAllMessage(toDeleteWithAsk, bundledUpdate), myUiParent, bundledUpdate)) {
          for (IdeaPluginDescriptorImpl descriptor : toDeleteWithAsk) {
            myPluginModel.uninstallAndUpdateUi(descriptor);
          }
          runFinishAction = true;
        }
      }

      for (IdeaPluginDescriptorImpl descriptor : toDelete) {
        myPluginModel.uninstallAndUpdateUi(descriptor);
      }

      if (runFinishAction || !toDelete.isEmpty()) {
        myOnFinishAction.run();
      }
    }
@Override
    public void actionPerformed(@NotNull AnActionEvent e)