LookupItem.HIGHLIGHTED_ATTR is never set in java completion, so don't check for it

This commit is contained in:
peter
2015-08-26 10:06:50 +02:00
parent 8ec12188b2
commit 90cb511f0d
4 changed files with 1 additions and 5 deletions
@@ -250,7 +250,6 @@ public class JavaMethodCallElement extends LookupItem<PsiMethod> implements Type
presentation.setIcon(DefaultLookupItemRenderer.getRawIcon(this, presentation.isReal()));
presentation.setStrikeout(JavaElementLookupRenderer.isToStrikeout(this));
presentation.setItemTextBold(getAttribute(HIGHLIGHTED_ATTR) != null);
MemberLookupHelper helper = myHelper != null ? myHelper : new MemberLookupHelper(myMethod, myContainingClass, false, false);
final Boolean qualify = getAttribute(FORCE_QUALIFY) != null ? Boolean.TRUE : myHelper == null ? Boolean.FALSE : null;
@@ -147,11 +147,9 @@ public class JavaPsiClassReferenceElement extends LookupItem<Object> {
presentation.setIcon(DefaultLookupItemRenderer.getRawIcon(item, presentation.isReal()));
}
final boolean bold = item.getAttribute(LookupItem.HIGHLIGHTED_ATTR) != null;
boolean strikeout = JavaElementLookupRenderer.isToStrikeout(item);
presentation.setItemText(getName(psiClass, item, diamond));
presentation.setStrikeout(strikeout);
presentation.setItemTextBold(bold);
String tailText = getLocationString(item);
PsiSubstitutor substitutor = (PsiSubstitutor)item.getAttribute(LookupItem.SUBSTITUTOR);
@@ -275,7 +275,7 @@ public class PsiTypeLookupItem extends LookupItem {
}
presentation.setItemText(((PsiType)object).getCanonicalText());
presentation.setItemTextBold(getAttribute(LookupItem.HIGHLIGHTED_ATTR) != null || object instanceof PsiPrimitiveType);
presentation.setItemTextBold(object instanceof PsiPrimitiveType);
if (isAddArrayInitializer()) {
presentation.setTailText("{...}");
}
@@ -43,7 +43,6 @@ public class JavaElementLookupRenderer implements ElementLookupRenderer {
presentation.setItemText(getName(element, item));
presentation.setStrikeout(isToStrikeout(item));
presentation.setItemTextBold(item.getAttribute(LookupItem.HIGHLIGHTED_ATTR) != null);
presentation.setTailText((String)item.getAttribute(LookupItem.TAIL_TEXT_ATTR), item.getAttribute(LookupItem.TAIL_TEXT_SMALL_ATTR) != null);