mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
insert common prefix by default, but only for explicit completion (for now)
This commit is contained in:
+1
-1
@@ -749,7 +749,7 @@ public class NormalCompletionTest extends LightFixtureCompletionTestCase {
|
||||
checkResultByFile(getTestName(false) + "_after.java")
|
||||
}
|
||||
|
||||
public void _testSecondInvocationToFillCommonPrefix() throws Throwable {
|
||||
public void testSecondInvocationToFillCommonPrefix() throws Throwable {
|
||||
configure()
|
||||
type('a');
|
||||
complete();
|
||||
|
||||
@@ -92,7 +92,7 @@ public class CodeInsightSettings implements PersistentStateComponent<Element>, C
|
||||
public boolean AUTOCOMPLETE_ON_CODE_COMPLETION = true;
|
||||
public boolean AUTOCOMPLETE_ON_SMART_TYPE_COMPLETION = true;
|
||||
public boolean AUTOCOMPLETE_ON_CLASS_NAME_COMPLETION = false;
|
||||
public boolean AUTOCOMPLETE_COMMON_PREFIX = false;
|
||||
public boolean AUTOCOMPLETE_COMMON_PREFIX = true;
|
||||
public boolean SHOW_STATIC_AFTER_INSTANCE = false;
|
||||
|
||||
public boolean SHOW_FULL_SIGNATURES_IN_PARAMETER_INFO = false;
|
||||
|
||||
-2
@@ -138,11 +138,9 @@ public class CodeCompletionHandlerBase implements CodeInsightActionHandler {
|
||||
|
||||
CompletionPhase phase = CompletionServiceImpl.getCompletionPhase();
|
||||
boolean repeated = phase.indicator != null && phase.indicator.isRepeatedInvocation(myCompletionType, editor);
|
||||
/*
|
||||
if (repeated && isAutocompleteCommonPrefixOnInvocation() && phase.fillInCommonPrefix()) {
|
||||
return;
|
||||
}
|
||||
*/
|
||||
|
||||
if (invokedExplicitly) {
|
||||
time = phase.newCompletionStarted(time, repeated);
|
||||
|
||||
@@ -185,6 +185,10 @@ public abstract class CompletionPhase implements Disposable {
|
||||
|
||||
@Override
|
||||
public boolean fillInCommonPrefix() {
|
||||
if (indicator.isAutopopupCompletion()) {
|
||||
return false;
|
||||
}
|
||||
|
||||
return indicator.fillInCommonPrefix(true);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user