This commit is contained in:
Alexander Kirillin
2013-06-25 15:21:36 +04:00
parent da5ea78c1b
commit 6c74dbc6b5
2 changed files with 5 additions and 1 deletions
@@ -15,10 +15,13 @@
*/
package com.intellij.lang.annotation;
import org.jetbrains.annotations.Nullable;
/**
* Unique object, which is the same for all of the problems of some group.
* It is used to split some inspection to several fake inspections
*/
public interface ProblemGroup {
@Nullable
String getProblemName();
}
@@ -766,7 +766,8 @@ public class HighlightInfo implements Segment {
List<IntentionAction> options = myOptions;
HighlightDisplayKey key = myKey;
if (myProblemGroup != null) {
HighlightDisplayKey problemGroupKey = HighlightDisplayKey.findById(myProblemGroup.getProblemName());
String problemName = myProblemGroup.getProblemName();
HighlightDisplayKey problemGroupKey = problemName != null ? HighlightDisplayKey.findById(problemName) : null;
if (problemGroupKey != null) {
key = problemGroupKey;
}