Skip to content

Commit

Permalink
devkit: determine required JDK version for IDEA SDK by ApplicationImp…
Browse files Browse the repository at this point in the history
…l class version instead of PsiManager, because PsiManager is from core-api which will remain on Java 1.6 after migration to Java 8
  • Loading branch information
chashnikov committed Dec 17, 2015
1 parent 2ccbe7b commit 3efc512
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions plugins/devkit/src/projectRoots/IdeaJdk.java
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@
package org.jetbrains.idea.devkit.projectRoots;

import com.intellij.openapi.application.PathManager;
import com.intellij.openapi.application.impl.ApplicationImpl;
import com.intellij.openapi.diagnostic.Logger;
import com.intellij.openapi.projectRoots.*;
import com.intellij.openapi.projectRoots.impl.JavaDependentSdkType;
Expand All @@ -32,7 +33,6 @@
import com.intellij.openapi.vfs.VirtualFile;
import com.intellij.openapi.vfs.VirtualFileManager;
import com.intellij.pom.java.LanguageLevel;
import com.intellij.psi.PsiManager;
import com.intellij.psi.impl.compiled.ClsParsingUtil;
import com.intellij.util.ArrayUtil;
import icons.DevkitIcons;
Expand Down Expand Up @@ -288,7 +288,7 @@ private static int getIdeaClassFileVersion(File apiJar) {
try {
ZipFile zipFile = new ZipFile(apiJar);
try {
ZipEntry entry = zipFile.getEntry(PsiManager.class.getName().replace('.', '/') + ".class");
ZipEntry entry = zipFile.getEntry(ApplicationImpl.class.getName().replace('.', '/') + ".class");
if (entry != null) {
DataInputStream stream = new DataInputStream(zipFile.getInputStream(entry));
try {
Expand Down

0 comments on commit 3efc512

Please sign in to comment.