mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
EA-127880 - PIEAE: CompositePsiElement.getContainingFile
GitOrigin-RevId: 4ef7e58976a0a96a8f03897046f431c824998c26
This commit is contained in:
committed by
intellij-monorepo-bot
parent
70223536e9
commit
471bfaa0fd
@@ -290,7 +290,10 @@ public class JavaMethodCallElement extends LookupItem<PsiMethod> implements Type
|
||||
}
|
||||
|
||||
public static void showParameterHints(LookupElement element, InsertionContext context, PsiMethod method, PsiCallExpression methodCall) {
|
||||
if (methodCall == null ||
|
||||
if (!CodeInsightSettings.getInstance().SHOW_PARAMETER_NAME_HINTS_ON_COMPLETION ||
|
||||
context.getCompletionChar() == Lookup.COMPLETE_STATEMENT_SELECT_CHAR ||
|
||||
context.getCompletionChar() == Lookup.REPLACE_SELECT_CHAR ||
|
||||
methodCall == null ||
|
||||
methodCall.getContainingFile() instanceof PsiCodeFragment ||
|
||||
element.getUserData(JavaMethodMergingContributor.MERGED_ELEMENT) != null) {
|
||||
return;
|
||||
@@ -298,10 +301,7 @@ public class JavaMethodCallElement extends LookupItem<PsiMethod> implements Type
|
||||
PsiParameterList parameterList = method.getParameterList();
|
||||
int parametersCount = parameterList.getParametersCount();
|
||||
PsiExpressionList parameterOwner = methodCall.getArgumentList();
|
||||
if (parameterOwner == null || !"()".equals(parameterOwner.getText()) ||
|
||||
parametersCount == 0 ||
|
||||
context.getCompletionChar() == Lookup.COMPLETE_STATEMENT_SELECT_CHAR || context.getCompletionChar() == Lookup.REPLACE_SELECT_CHAR ||
|
||||
!CodeInsightSettings.getInstance().SHOW_PARAMETER_NAME_HINTS_ON_COMPLETION) {
|
||||
if (parameterOwner == null || !"()".equals(parameterOwner.getText()) || parametersCount == 0) {
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user