boolean (@NotNull Project project, Editor editor, PsiFile file) { if (InjectedLanguageManager.getInstance(project).isInjectedFragment(file)) { PsiElement psiElement = getStartElement(); if (psiElement == null || psiElement.getContainingFile() != file) return false; } return isAvailable(); }