mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
Do not close completion popup on % (WEB-26250)
This commit is contained in:
+2
-2
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2000-2013 JetBrains s.r.o.
|
||||
* Copyright 2000-2017 JetBrains s.r.o.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
@@ -28,7 +28,7 @@ public class LiveTemplateCharFilter extends CharFilter {
|
||||
public Result acceptChar(char c, int prefixLength, Lookup lookup) {
|
||||
LookupElement item = lookup.getCurrentItem();
|
||||
if (item instanceof LiveTemplateLookupElement && lookup.isCompletion()) {
|
||||
if (Character.isJavaIdentifierPart(c)) return Result.ADD_TO_PREFIX;
|
||||
if (Character.isJavaIdentifierPart(c) || c == '%') return Result.ADD_TO_PREFIX;
|
||||
|
||||
if (c == ((LiveTemplateLookupElement)item).getTemplateShortcut()) {
|
||||
return Result.SELECT_ITEM_AND_FINISH_LOOKUP;
|
||||
|
||||
Reference in New Issue
Block a user