don't restart completion after typing 2 characters: it's not needed with current matching

This commit is contained in:
peter
2012-10-15 17:14:44 +02:00
parent 18a6cf6a1b
commit f653df321f
4 changed files with 0 additions and 38 deletions
@@ -1,13 +0,0 @@
public class TestCase extends Zzz {
{
int fai1;
int fai2;
int fai3;
f<caret>
}
}
class Zzz {
private void fax() {}
}
@@ -1,13 +0,0 @@
public class TestCase extends Zzz {
{
int fai1;
int fai2;
int fai3;
fai<caret>
}
}
class Zzz {
private void fax() {}
}
@@ -847,14 +847,6 @@ public class ListUtils {
checkResultByFile(getTestName(false) + "_after.java")
}
public void testSecondInvocationToFillCommonPrefix() throws Throwable {
configure()
type('a');
complete();
assertStringItems("fai1", "fai2", "fai3");
checkResult()
}
public void testSuggestInaccessibleOnSecondInvocation() throws Throwable {
configure()
assertStringItems("_bar", "_goo");
@@ -54,7 +54,6 @@ import com.intellij.openapi.util.TextRange;
import com.intellij.openapi.util.registry.Registry;
import com.intellij.openapi.util.text.StringUtil;
import com.intellij.patterns.ElementPattern;
import com.intellij.patterns.StandardPatterns;
import com.intellij.psi.PsiFile;
import com.intellij.psi.PsiReference;
import com.intellij.psi.ReferenceRange;
@@ -371,9 +370,6 @@ public class CompletionProgressIndicator extends ProgressIndicatorBase implement
myCount++;
if (myCount == 1) {
// real middle matching variants are added only with prefix of length >=2
addWatchedPrefix(myParameters.getOffset() - item.getPrefixMatcher().getPrefix().length(), StandardPatterns.string().withLength(2));
new Alarm(Alarm.ThreadToUse.SHARED_THREAD, this).addRequest(new Runnable() {
@Override
public void run() {