Skip to content

Commit

Permalink
highlight info compatibility fix
Browse files Browse the repository at this point in the history
  • Loading branch information
nicity committed Nov 17, 2013
1 parent 3ed903f commit dd0f816
Showing 1 changed file with 5 additions and 12 deletions.
17 changes: 5 additions & 12 deletions src/com/advancedtools/cpp/hilighting/HighlightCommand.java
Original file line number Diff line number Diff line change
Expand Up @@ -239,20 +239,13 @@ public void addMessage(MessageType type, int start, int end, String message, Fix
final HighlightInfoType highlightInfoType = type == MessageType.Info ? HighlightInfoType.INFORMATION :
type == MessageType.Warning ? HighlightInfoType.WARNING : HighlightInfoType.ERROR;

HighlightInfo highlightInfo = HighlightInfo.createHighlightInfo(
highlightInfoType,
range,
message
);
HighlightInfo highlightInfo = HighlightInfo.newHighlightInfo(
highlightInfoType).range(range).description(message).create();

if (highlightInfo == null) {
highlightInfo = HighlightInfo.createHighlightInfo(
highlightInfoType,
range,
message,
null,
emptyTextAttrs
);
highlightInfo = HighlightInfo.newHighlightInfo(highlightInfoType).range(range).
description(message).textAttributes(emptyTextAttrs).create();

}

highlightHolder.add(highlightInfo);
Expand Down

0 comments on commit dd0f816

Please sign in to comment.