mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
remove show.all.classes.on.first.completion from registry
This commit is contained in:
+1
-6
@@ -32,7 +32,6 @@ import com.intellij.openapi.editor.highlighter.HighlighterIterator;
|
||||
import com.intellij.openapi.project.Project;
|
||||
import com.intellij.openapi.util.Comparing;
|
||||
import com.intellij.openapi.util.Condition;
|
||||
import com.intellij.openapi.util.registry.Registry;
|
||||
import com.intellij.openapi.util.text.StringUtil;
|
||||
import com.intellij.patterns.ElementPattern;
|
||||
import com.intellij.patterns.PatternCondition;
|
||||
@@ -262,7 +261,7 @@ public class JavaCompletionContributor extends CompletionContributor {
|
||||
return;
|
||||
}
|
||||
|
||||
if (mayShowAllClasses(parameters)) {
|
||||
if (parameters.getInvocationCount() >= 2) {
|
||||
JavaClassNameCompletionContributor.addAllClasses(parameters, parameters.getInvocationCount() <= 2, result.getPrefixMatcher(), new Consumer<LookupElement>() {
|
||||
@Override
|
||||
public void consume(LookupElement element) {
|
||||
@@ -408,10 +407,6 @@ public class JavaCompletionContributor extends CompletionContributor {
|
||||
return true;
|
||||
}
|
||||
|
||||
public static boolean mayShowAllClasses(CompletionParameters parameters) {
|
||||
return Registry.is("show.all.classes.on.first.completion") || parameters.getInvocationCount() >= 2;
|
||||
}
|
||||
|
||||
public static boolean mayStartClassName(CompletionResultSet result) {
|
||||
String prefix = result.getPrefixMatcher().getPrefix();
|
||||
if (StringUtil.isEmpty(prefix)) {
|
||||
|
||||
@@ -198,7 +198,6 @@ ide.completion.middle.matching.description=Suggest items in completion that cont
|
||||
ide.goto.middle.matching=false
|
||||
ide.goto.middle.matching.description=Suggest items in goto actions that contain the entered string somewhere in the middle
|
||||
|
||||
show.all.classes.on.first.completion=false
|
||||
ide.enable.toolwindow.stack=false
|
||||
|
||||
change.signature.awesome.mode=true
|
||||
|
||||
+1
-1
@@ -335,7 +335,7 @@ public class GroovyCompletionContributor extends CompletionContributor {
|
||||
|
||||
if (isClassNamePossible(position) && JavaCompletionContributor.mayStartClassName(result)) {
|
||||
result.stopHere();
|
||||
if (JavaCompletionContributor.mayShowAllClasses(parameters)) {
|
||||
if (parameters.getInvocationCount() >= 2) {
|
||||
addAllClasses(parameters, result, inheritors);
|
||||
} else {
|
||||
JavaCompletionContributor.advertiseSecondCompletion(position.getProject());
|
||||
|
||||
Reference in New Issue
Block a user