From b6092ce4730fb3774ad3761767bb790eec0198c8 Mon Sep 17 00:00:00 2001 From: Peter Gromov Date: Wed, 16 Sep 2009 15:19:37 +0400 Subject: [PATCH] finally remove LookupElement#getGrouping() together with its ruby clients rework --- .../src/com/intellij/codeInsight/lookup/LookupElement.java | 7 ------- .../codeInsight/lookup/LookupElementDecorator.java | 5 ----- .../intellij/codeInsight/completion/GroupingWeigher.java | 2 +- .../src/com/intellij/codeInsight/lookup/LookupItem.java | 5 ----- 4 files changed, 1 insertion(+), 18 deletions(-) diff --git a/platform/lang-api/src/com/intellij/codeInsight/lookup/LookupElement.java b/platform/lang-api/src/com/intellij/codeInsight/lookup/LookupElement.java index 88befb86937d..76a66b14b337 100644 --- a/platform/lang-api/src/com/intellij/codeInsight/lookup/LookupElement.java +++ b/platform/lang-api/src/com/intellij/codeInsight/lookup/LookupElement.java @@ -77,13 +77,6 @@ public abstract class LookupElement extends UserDataHolderBase { presentation.setItemText(getLookupString()); } - /** - * @deprecated use {@link com.intellij.codeInsight.completion.PrioritizedLookupElement} - */ - public int getGrouping() { - return 0; - } - @Nullable public T as(Class aClass) { //noinspection unchecked diff --git a/platform/lang-api/src/com/intellij/codeInsight/lookup/LookupElementDecorator.java b/platform/lang-api/src/com/intellij/codeInsight/lookup/LookupElementDecorator.java index db1b8b6ee4f6..f6187e21cdce 100644 --- a/platform/lang-api/src/com/intellij/codeInsight/lookup/LookupElementDecorator.java +++ b/platform/lang-api/src/com/intellij/codeInsight/lookup/LookupElementDecorator.java @@ -102,11 +102,6 @@ public abstract class LookupElementDecorator extends Lo return myDelegate.hashCode(); } - @Override - public int getGrouping() { - return myDelegate.getGrouping(); - } - @NotNull public static LookupElementDecorator withInsertHandler(@NotNull T element, @NotNull final InsertHandler> insertHandler) { return new InsertingDecorator(element, insertHandler); diff --git a/platform/lang-impl/src/com/intellij/codeInsight/completion/GroupingWeigher.java b/platform/lang-impl/src/com/intellij/codeInsight/completion/GroupingWeigher.java index 7a5cd5fa8526..dc8236ae77dd 100644 --- a/platform/lang-impl/src/com/intellij/codeInsight/completion/GroupingWeigher.java +++ b/platform/lang-impl/src/com/intellij/codeInsight/completion/GroupingWeigher.java @@ -14,6 +14,6 @@ public class GroupingWeigher extends CompletionWeigher { return -prioritized.getGrouping(); } - return -element.getGrouping(); + return 0; } } diff --git a/platform/lang-impl/src/com/intellij/codeInsight/lookup/LookupItem.java b/platform/lang-impl/src/com/intellij/codeInsight/lookup/LookupItem.java index 96212086f6e3..475d2420ceff 100644 --- a/platform/lang-impl/src/com/intellij/codeInsight/lookup/LookupItem.java +++ b/platform/lang-impl/src/com/intellij/codeInsight/lookup/LookupItem.java @@ -298,11 +298,6 @@ public class LookupItem extends MutableLookupElement implements Comparable return myPriority; } - @Override - public final int getGrouping() { - return myGrouping; - } - @NotNull public LookupItem setPresentableText(@NotNull final String displayText) { myPresentable = displayText;