mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
IDEA-89745 Stange completion insert handling (Java)
This commit is contained in:
@@ -109,7 +109,7 @@ public class JavaChainLookupElement extends LookupElementDecorator<LookupElement
|
||||
final InsertionContext qualifierContext = CompletionUtil.emulateInsertion(context, context.getStartOffset(), myQualifier);
|
||||
OffsetKey oldStart = context.trackOffset(context.getStartOffset(), false);
|
||||
|
||||
int start = CharArrayUtil.shiftForward(context.getDocument().getCharsSequence(), context.getStartOffset(), " \t");
|
||||
int start = CharArrayUtil.shiftForward(context.getDocument().getCharsSequence(), context.getStartOffset(), " \t\n");
|
||||
if (shouldParenthesizeQualifier(context.getFile(), start, qualifierContext.getTailOffset())) {
|
||||
final String space = CodeStyleSettingsManager.getSettings(qualifierContext.getProject()).SPACE_WITHIN_PARENTHESES ? " " : "";
|
||||
document.insertString(start, "(" + space);
|
||||
|
||||
Reference in New Issue
Block a user