mirror of
https://gitflic.ru/project/openide/openide.git
synced 2025-12-16 14:23:28 +07:00
[codeInspection.ui] Rename ActionToRegister to ProfilePanelAction
IJ-CR-123493 GitOrigin-RevId: 32081af4a5148b038ce72c7273f325b6f394d8e8
This commit is contained in:
committed by
intellij-monorepo-bot
parent
b7ca72a251
commit
9bb4157e09
@@ -26,8 +26,8 @@ public class RegExpProfileActionProvider extends InspectionProfileActionProvider
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<ActionToRegister> getActionsToRegister(SingleInspectionProfilePanel panel) {
|
||||
return List.of(new ActionToRegister(getActionGroup(panel), "regexp.profile.action.provider.add.group"));
|
||||
public List<ProfilePanelAction> getProfilePanelActions(SingleInspectionProfilePanel panel) {
|
||||
return List.of(new ProfilePanelAction(getActionGroup(panel), "regexp.profile.action.provider.add.group"));
|
||||
}
|
||||
|
||||
@NotNull
|
||||
|
||||
@@ -50,11 +50,11 @@ public abstract class InspectionProfileActionProvider {
|
||||
*/
|
||||
public void deleteInspection(InspectionProfileEntry entry, String shortName) {}
|
||||
|
||||
public record ActionToRegister(@NotNull AnAction action, @NotNull String actionId) {}
|
||||
public record ProfilePanelAction(@NotNull AnAction action, @NotNull String actionId) {}
|
||||
|
||||
/**
|
||||
* @return list of actions registered in the inspection profile configurable UI.<br>
|
||||
* @return list of actions to be stored in the inspection profile configurable UI.<br>
|
||||
* Such actions can be called from inspection descriptions with {@code <a href="action:id"></a>}.
|
||||
*/
|
||||
public List<ActionToRegister> getActionsToRegister(SingleInspectionProfilePanel panel) { return List.of(); }
|
||||
public List<ProfilePanelAction> getProfilePanelActions(SingleInspectionProfilePanel panel) { return List.of(); }
|
||||
}
|
||||
|
||||
@@ -1150,7 +1150,7 @@ public class SingleInspectionProfilePanel extends JPanel {
|
||||
}
|
||||
else if (url.getScheme().equals("action") && panel != null) {
|
||||
final var action = InspectionProfileActionProvider.EP_NAME.getExtensionList().stream()
|
||||
.flatMap(provider -> provider.getActionsToRegister(panel).stream())
|
||||
.flatMap(provider -> provider.getProfilePanelActions(panel).stream())
|
||||
.filter(a -> a.actionId().equals(url.getAuthority()))
|
||||
.findFirst();
|
||||
if (action.isPresent()) {
|
||||
|
||||
@@ -56,8 +56,8 @@ public class StructuralSearchProfileActionProvider extends InspectionProfileActi
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<ActionToRegister> getActionsToRegister(SingleInspectionProfilePanel panel) {
|
||||
return List.of(new ActionToRegister(getActionGroup(panel), "ssr.profile.action.provider.add.group"));
|
||||
public List<ProfilePanelAction> getProfilePanelActions(SingleInspectionProfilePanel panel) {
|
||||
return List.of(new ProfilePanelAction(getActionGroup(panel), "ssr.profile.action.provider.add.group"));
|
||||
}
|
||||
|
||||
@NotNull
|
||||
|
||||
Reference in New Issue
Block a user