List<Module> (@NotNull Project project, @NotNull List<Module> pluginModules) { String message = DevKitBundle.message("select.plugin.module.to.patch"); ChoosePluginModuleDialog chooseModulesDialog = new ChoosePluginModuleDialog(project, pluginModules, message, null); chooseModulesDialog.setSingleSelectionMode(); chooseModulesDialog.show(); List<Module> selectedModules = chooseModulesDialog.getChosenElements(); if (selectedModules.isEmpty()) { return null; // Dialog has been cancelled } return selectedModules; }