mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
IJPL-207762 hide hacky AutoPopupController.ALLOW_AUTO_POPUP_FOR_SLASHES_IN_PATHS flag from API
GitOrigin-RevId: c3e2cd9021d61d75a4d50a61b5f2b91badee28d7
This commit is contained in:
committed by
intellij-monorepo-bot
parent
d79c6ad1d1
commit
832d0349e8
@@ -83,7 +83,6 @@ e:com.intellij.codeHighlighting.TextEditorHighlightingPassRegistrar$Anchor
|
||||
- s:valueOf(java.lang.String):com.intellij.codeHighlighting.TextEditorHighlightingPassRegistrar$Anchor
|
||||
- s:values():com.intellij.codeHighlighting.TextEditorHighlightingPassRegistrar$Anchor[]
|
||||
a:com.intellij.codeInsight.AutoPopupController
|
||||
- sf:ALLOW_AUTO_POPUP_FOR_SLASHES_IN_PATHS:com.intellij.openapi.util.Key
|
||||
- sf:ALWAYS_AUTO_POPUP:com.intellij.openapi.util.Key
|
||||
- sf:AUTO_POPUP_ON_FOCUS_GAINED:com.intellij.openapi.util.Key
|
||||
- sf:NO_ADS:com.intellij.openapi.util.Key
|
||||
|
||||
@@ -36,7 +36,10 @@ public abstract class AutoPopupController {
|
||||
/**
|
||||
* Setting this user data key to the editor with a completion provider
|
||||
* allows showing the auto popup for slashes
|
||||
* @deprecated Implement your own {@link com.intellij.codeInsight.editorActions.TypedHandlerDelegate#checkAutoPopup(char, Project, Editor, PsiFile)}
|
||||
*/
|
||||
@ApiStatus.Internal
|
||||
@Deprecated
|
||||
public static final Key<Boolean> ALLOW_AUTO_POPUP_FOR_SLASHES_IN_PATHS = Key.create("Allow Auto-Popup For Slashes In Paths");
|
||||
|
||||
/**
|
||||
|
||||
@@ -333,8 +333,10 @@ public final class TypedHandler extends TypedActionHandlerBase {
|
||||
* and implement {@link TypedHandlerDelegate#checkAutoPopup}
|
||||
*/
|
||||
public static void autoPopupCompletion(@NotNull Editor editor, char charTyped, @NotNull Project project, @NotNull PsiFile file) {
|
||||
boolean allowSlashes = Boolean.TRUE.equals(editor.getUserData(AutoPopupController.ALLOW_AUTO_POPUP_FOR_SLASHES_IN_PATHS));
|
||||
if (charTyped == '.' || (allowSlashes && charTyped == '/') || isAutoPopup(editor, file, charTyped)) {
|
||||
if (charTyped == '.' ||
|
||||
(charTyped == '/' && Boolean.TRUE.equals(editor.getUserData(AutoPopupController.ALLOW_AUTO_POPUP_FOR_SLASHES_IN_PATHS))) || // todo rewrite with TypedHandlerDelegate#checkAutoPopup
|
||||
isAutoPopup(editor, file, charTyped)
|
||||
) {
|
||||
AutoPopupController.getInstance(project).scheduleAutoPopup(editor);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user