IDEA-121675 Nashorn: Debug: RunToCursor is always disabled when js file is active

This commit is contained in:
Egor.Ushakov
2014-03-05 15:25:56 +04:00
parent f4d023920d
commit 33b01458a5
@@ -88,7 +88,8 @@ public abstract class JavaLineBreakpointTypeBase<P extends JavaBreakpointPropert
public final boolean canPutAt(@NotNull VirtualFile file, final int line, @NotNull Project project) {
PsiFile psiFile = PsiManager.getInstance(project).findFile(file);
// JSPX supports jvm debugging, but not in XHTML files
if (psiFile == null || psiFile.getVirtualFile().getFileType() == StdFileTypes.XHTML) {
// JS has it's own breakpoints
if (psiFile == null || psiFile.getVirtualFile().getFileType() == StdFileTypes.XHTML || psiFile.getVirtualFile().getFileType() == StdFileTypes.JS) {
return false;
}