Why does API 22 insist on joining JDK 1.6?

I am trying to work with Java 1.7 in IntelliJ (Android Studio is enough), and I believe that I already have Java 1.7, but for some reason it insists that my version is Java 1.6 for (API 22). Here are some screenshots:

enter image description here

enter image description here

enter image description here

I have the following in build.gradle:

compileOptions {
    sourceCompatibility JavaVersion.VERSION_1_7
    targetCompatibility JavaVersion.VERSION_1_7
}

I can use 1.7 functions, but 1.6 is displayed in the dialog box, which makes me feel very uneasy. Did I miss something?

thanks

+4
source share
1 answer

Make sure it File|Project Structure|SDK Location|JDK Locationpoints to the correct Java

0
source

Source: https://habr.com/ru/post/1612321/


All Articles