diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index d8a456ff2..974784a5a 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -36,11 +36,11 @@ jobs: steps: - uses: actions/checkout@v2 - - name: set up Java 17 + - name: set up Java 21 uses: actions/setup-java@v2 with: distribution: 'adopt' - java-version: '17' + java-version: '21' - name: Build and check run: | @@ -54,11 +54,11 @@ jobs: steps: - uses: actions/checkout@v2 - - name: set up Java 17 + - name: set up Java 21 uses: actions/setup-java@v2 with: distribution: 'adopt' - java-version: '17' + java-version: '21' - name: Build and check run: cd WearOS && ./gradlew build @@ -70,11 +70,11 @@ jobs: steps: - uses: actions/checkout@v2 - - name: set up Java 17 + - name: set up Java 21 uses: actions/setup-java@v2 with: distribution: 'adopt' - java-version: '17' + java-version: '21' - name: Build and check run: | @@ -88,11 +88,11 @@ jobs: steps: - uses: actions/checkout@v2 - - name: set up Java 17 + - name: set up Java 21 uses: actions/setup-java@v2 with: distribution: 'adopt' - java-version: '17' + java-version: '21' - name: Build and check run: | diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 93e19066a..c242814d9 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -26,11 +26,11 @@ jobs: with: token: ${{ secrets.SYNCED_GITHUB_TOKEN_REPO }} - - name: set up Java 17 + - name: set up Java 21 uses: actions/setup-java@v3 with: distribution: 'temurin' - java-version: '17' + java-version: '21' - name: Build APKs run: | diff --git a/ApiDemos/java/app/build.gradle b/ApiDemos/java/app/build.gradle index ef7020bcd..3e589fac8 100644 --- a/ApiDemos/java/app/build.gradle +++ b/ApiDemos/java/app/build.gradle @@ -36,8 +36,8 @@ android { } } compileOptions { - sourceCompatibility JavaVersion.VERSION_17 - targetCompatibility JavaVersion.VERSION_17 + sourceCompatibility JavaVersion.VERSION_21 + targetCompatibility JavaVersion.VERSION_21 } namespace "com.example.mapdemo" } diff --git a/ApiDemos/kotlin/app/build.gradle b/ApiDemos/kotlin/app/build.gradle index bffe304f6..e2254dca1 100644 --- a/ApiDemos/kotlin/app/build.gradle +++ b/ApiDemos/kotlin/app/build.gradle @@ -36,8 +36,8 @@ android { } } compileOptions { - sourceCompatibility JavaVersion.VERSION_17 - targetCompatibility JavaVersion.VERSION_17 + sourceCompatibility JavaVersion.VERSION_21 + targetCompatibility JavaVersion.VERSION_21 } lintOptions { abortOnError false diff --git a/WearOS/Wearable/build.gradle b/WearOS/Wearable/build.gradle index a156c9e1c..fe8b82aa4 100644 --- a/WearOS/Wearable/build.gradle +++ b/WearOS/Wearable/build.gradle @@ -39,17 +39,16 @@ android { namespace 'com.example.wearosmap' kotlinOptions { - jvmTarget = "17" + jvmTarget = "21" } kotlin { - jvmToolchain(17) + jvmToolchain(21) } } // [START maps_wear_os_dependencies] dependencies { // [START_EXCLUDE] - implementation fileTree(dir: 'libs', include: ['*.jar']) implementation "androidx.core:core-ktx:1.13.1" implementation 'org.jetbrains.kotlin:kotlin-stdlib-jdk7:2.0.0' // [END_EXCLUDE] diff --git a/snippets/app-compose/build.gradle b/snippets/app-compose/build.gradle index 77d6f9ef4..333e2ae1b 100644 --- a/snippets/app-compose/build.gradle +++ b/snippets/app-compose/build.gradle @@ -32,11 +32,11 @@ android { buildConfig = true } compileOptions { - sourceCompatibility JavaVersion.VERSION_1_8 - targetCompatibility JavaVersion.VERSION_1_8 + sourceCompatibility JavaVersion.VERSION_21 + targetCompatibility JavaVersion.VERSION_21 } kotlinOptions { - jvmTarget = '1.8' + jvmTarget = '21' } } @@ -44,7 +44,6 @@ android { dependencies { // [START_EXCLUDE silent] - implementation fileTree(dir: "libs", include: ["*.jar"]) implementation 'org.jetbrains.kotlin:kotlin-stdlib:2.0.0' implementation 'androidx.core:core-ktx:1.13.1' implementation 'androidx.appcompat:appcompat:1.7.0' diff --git a/snippets/app-ktx/build.gradle b/snippets/app-ktx/build.gradle index 04fbbf8a2..95feed4ce 100644 --- a/snippets/app-ktx/build.gradle +++ b/snippets/app-ktx/build.gradle @@ -31,11 +31,11 @@ android { } } compileOptions { - sourceCompatibility JavaVersion.VERSION_1_8 - targetCompatibility JavaVersion.VERSION_1_8 + sourceCompatibility JavaVersion.VERSION_21 + targetCompatibility JavaVersion.VERSION_21 } kotlinOptions { - jvmTarget = '1.8' + jvmTarget = '21' } } diff --git a/snippets/app-places-ktx/build.gradle b/snippets/app-places-ktx/build.gradle index 89e701e0f..d7fb8f586 100644 --- a/snippets/app-places-ktx/build.gradle +++ b/snippets/app-places-ktx/build.gradle @@ -29,11 +29,11 @@ android { } } compileOptions { - sourceCompatibility JavaVersion.VERSION_1_8 - targetCompatibility JavaVersion.VERSION_1_8 + sourceCompatibility JavaVersion.VERSION_21 + targetCompatibility JavaVersion.VERSION_21 } kotlinOptions { - jvmTarget = '1.8' + jvmTarget = '21' } } // [START places_android_ktx_install_snippet] diff --git a/snippets/app-rx/build.gradle b/snippets/app-rx/build.gradle index 9a92084e8..480c14991 100644 --- a/snippets/app-rx/build.gradle +++ b/snippets/app-rx/build.gradle @@ -29,11 +29,11 @@ android { } } compileOptions { - sourceCompatibility JavaVersion.VERSION_1_8 - targetCompatibility JavaVersion.VERSION_1_8 + sourceCompatibility JavaVersion.VERSION_21 + targetCompatibility JavaVersion.VERSION_21 } kotlinOptions { - jvmTarget = '1.8' + jvmTarget = '21' } } diff --git a/snippets/app-utils-ktx/build.gradle b/snippets/app-utils-ktx/build.gradle index 3137f15c1..ffd133252 100644 --- a/snippets/app-utils-ktx/build.gradle +++ b/snippets/app-utils-ktx/build.gradle @@ -29,11 +29,11 @@ android { } } compileOptions { - sourceCompatibility JavaVersion.VERSION_1_8 - targetCompatibility JavaVersion.VERSION_1_8 + sourceCompatibility JavaVersion.VERSION_21 + targetCompatibility JavaVersion.VERSION_21 } kotlinOptions { - jvmTarget = '1.8' + jvmTarget = '21' } } diff --git a/snippets/app-utils/build.gradle b/snippets/app-utils/build.gradle index d96c0983f..1412e44db 100644 --- a/snippets/app-utils/build.gradle +++ b/snippets/app-utils/build.gradle @@ -29,11 +29,11 @@ android { } } compileOptions { - sourceCompatibility JavaVersion.VERSION_1_8 - targetCompatibility JavaVersion.VERSION_1_8 + sourceCompatibility JavaVersion.VERSION_21 + targetCompatibility JavaVersion.VERSION_21 } kotlinOptions { - jvmTarget = '1.8' + jvmTarget = '21' } } diff --git a/snippets/app/build.gradle b/snippets/app/build.gradle index 6ed2a74a4..a96740273 100644 --- a/snippets/app/build.gradle +++ b/snippets/app/build.gradle @@ -41,8 +41,8 @@ android { } compileOptions { - sourceCompatibility JavaVersion.VERSION_17 - targetCompatibility JavaVersion.VERSION_17 + sourceCompatibility JavaVersion.VERSION_21 + targetCompatibility JavaVersion.VERSION_21 } namespace 'com.google.maps.example' } @@ -50,12 +50,11 @@ android { // [START maps_android_play_services_maps_dependency] dependencies { // [START_EXCLUDE silent] - implementation fileTree(dir: "libs", include: ["*.jar"]) implementation 'org.jetbrains.kotlin:kotlin-stdlib:2.0.0' implementation 'androidx.core:core-ktx:1.13.1' implementation 'androidx.appcompat:appcompat:1.7.0' - implementation "androidx.compose.foundation:foundation:1.7.0-beta04" - implementation "androidx.compose.material:material:1.7.0-beta04" + implementation "androidx.compose.foundation:foundation:1.7.0-beta05" + implementation "androidx.compose.material:material:1.7.0-beta05" implementation 'com.google.android.material:material:1.12.0' implementation 'androidx.constraintlayout:constraintlayout:2.1.4' implementation 'androidx.navigation:navigation-fragment-ktx:2.7.7' diff --git a/snippets/app/src/gms/java/com/google/maps/example/AdvancedMarkersCollisionActivity.java b/snippets/app/src/gms/java/com/google/maps/example/AdvancedMarkersCollisionActivity.java new file mode 100644 index 000000000..0b0fc192c --- /dev/null +++ b/snippets/app/src/gms/java/com/google/maps/example/AdvancedMarkersCollisionActivity.java @@ -0,0 +1,44 @@ +// Copyright 2024 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +package com.google.maps.example; + +import android.os.Bundle; + +import androidx.annotation.Nullable; +import androidx.appcompat.app.AppCompatActivity; + +import com.google.android.gms.maps.GoogleMap; +import com.google.android.gms.maps.model.AdvancedMarkerOptions; +import com.google.android.gms.maps.model.AdvancedMarkerOptions.CollisionBehavior; +import com.google.android.gms.maps.model.LatLng; +import com.google.android.gms.maps.model.Marker; + +class AdvancedMarkersCollisionActivity extends AppCompatActivity { + + private GoogleMap map; + + @Override + protected void onCreate(@Nullable Bundle savedInstanceState) { + super.onCreate(savedInstanceState); + // [START maps_android_marker_collision] + Marker marker = map.addMarker( + new AdvancedMarkerOptions() + .position(new LatLng(10.0, 10.0)) + .zIndex(10f) // Optional. + .collisionBehavior(CollisionBehavior.OPTIONAL_AND_HIDES_LOWER_PRIORITY) + ); + // [END maps_android_marker_collision] + } +} diff --git a/snippets/app/src/gms/java/com/google/maps/example/CloudBasedMapStylingActivity.java b/snippets/app/src/gms/java/com/google/maps/example/CloudBasedMapStylingActivity.java new file mode 100644 index 000000000..2dc12c0d9 --- /dev/null +++ b/snippets/app/src/gms/java/com/google/maps/example/CloudBasedMapStylingActivity.java @@ -0,0 +1,35 @@ +// Copyright 2024 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +package com.google.maps.example; + +import android.os.Bundle; + +import androidx.appcompat.app.AppCompatActivity; + +import com.google.android.gms.maps.GoogleMapOptions; +import com.google.android.gms.maps.MapFragment; + +public class CloudBasedMapStylingActivity extends AppCompatActivity { + + @Override + protected void onCreate(Bundle savedInstanceState) { + super.onCreate(savedInstanceState); + // [START maps_android_cloud_based_map_styling] + MapFragment mapFragment = MapFragment.newInstance( + new GoogleMapOptions() + .mapId(getResources().getString(R.string.map_id))); + // [END maps_android_cloud_based_map_styling] + } +} diff --git a/snippets/app/src/gms/java/com/google/maps/example/PolylineCustomizationActivity.java b/snippets/app/src/gms/java/com/google/maps/example/PolylineCustomizationActivity.java new file mode 100644 index 000000000..041ffb44f --- /dev/null +++ b/snippets/app/src/gms/java/com/google/maps/example/PolylineCustomizationActivity.java @@ -0,0 +1,62 @@ +// Copyright 2024 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +package com.google.maps.example; + +import android.graphics.Color; + +import androidx.appcompat.app.AppCompatActivity; + +import com.google.android.gms.maps.GoogleMap; +import com.google.android.gms.maps.model.BitmapDescriptorFactory; +import com.google.android.gms.maps.model.LatLng; +import com.google.android.gms.maps.model.Polyline; +import com.google.android.gms.maps.model.PolylineOptions; +import com.google.android.gms.maps.model.StampStyle; +import com.google.android.gms.maps.model.StrokeStyle; +import com.google.android.gms.maps.model.StyleSpan; +import com.google.android.gms.maps.model.TextureStyle; + +public class PolylineCustomizationActivity extends AppCompatActivity { + + private GoogleMap map; + + private void multicoloredPolyline() { + // [START maps_android_polyline_multicolored] + Polyline line = map.addPolyline(new PolylineOptions() + .add(new LatLng(47.6677146,-122.3470447), new LatLng(47.6442757,-122.2814693)) + .addSpan(new StyleSpan(Color.RED)) + .addSpan(new StyleSpan(Color.GREEN))); + // [END maps_android_polyline_multicolored] + } + + private void multicoloredGradientPolyline() { + // [START maps_android_polyline_gradient] + Polyline line = map.addPolyline(new PolylineOptions() + .add(new LatLng(47.6677146,-122.3470447), new LatLng(47.6442757,-122.2814693)) + .addSpan(new StyleSpan(StrokeStyle.gradientBuilder(Color.RED, Color.YELLOW).build()))); + // [END maps_android_polyline_gradient] + } + + private void stampedPolyline() { + // [START maps_android_polyline_stamped] + StampStyle stampStyle = + TextureStyle.newBuilder(BitmapDescriptorFactory.fromResource(R.drawable.walking_dot)).build(); + StyleSpan span = new StyleSpan(StrokeStyle.colorBuilder(Color.RED).stamp(stampStyle).build()); + map.addPolyline(new PolylineOptions() + .add(new LatLng(47.6677146,-122.3470447), new LatLng(47.6442757,-122.2814693)) + .addSpan(span)); + // [END maps_android_polyline_stamped] + } +} diff --git a/snippets/app/src/gms/java/com/google/maps/example/kotlin/AdvancedMarkersCollisionActivity.kt b/snippets/app/src/gms/java/com/google/maps/example/kotlin/AdvancedMarkersCollisionActivity.kt new file mode 100644 index 000000000..5e20b7ce8 --- /dev/null +++ b/snippets/app/src/gms/java/com/google/maps/example/kotlin/AdvancedMarkersCollisionActivity.kt @@ -0,0 +1,39 @@ +// Copyright 2024 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +package com.google.maps.example.kotlin + +import android.os.Bundle +import androidx.appcompat.app.AppCompatActivity +import com.google.android.gms.maps.GoogleMap +import com.google.android.gms.maps.model.AdvancedMarkerOptions +import com.google.android.gms.maps.model.AdvancedMarkerOptions.CollisionBehavior +import com.google.android.gms.maps.model.LatLng + +class AdvancedMarkersCollisionActivity : AppCompatActivity() { + + private lateinit var map: GoogleMap + + override fun onCreate(savedInstanceState: Bundle?) { + super.onCreate(savedInstanceState) + // [START maps_android_marker_collision] + val marker = map.addMarker( + AdvancedMarkerOptions() + .position(LatLng(10.0, 10.0)) + .zIndex(10f) // Optional. + .collisionBehavior(CollisionBehavior.OPTIONAL_AND_HIDES_LOWER_PRIORITY) + ) + // [END maps_android_marker_collision] + } +} \ No newline at end of file diff --git a/snippets/app/src/gms/java/com/google/maps/example/kotlin/CloudBasedMapStylingActivity.kt b/snippets/app/src/gms/java/com/google/maps/example/kotlin/CloudBasedMapStylingActivity.kt new file mode 100644 index 000000000..ffece1959 --- /dev/null +++ b/snippets/app/src/gms/java/com/google/maps/example/kotlin/CloudBasedMapStylingActivity.kt @@ -0,0 +1,33 @@ +// Copyright 2024 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +package com.google.maps.example.kotlin + +import android.os.Bundle +import androidx.appcompat.app.AppCompatActivity +import com.google.android.gms.maps.GoogleMapOptions +import com.google.android.gms.maps.MapFragment +import com.google.maps.example.R + +class CloudBasedMapStylingActivity : AppCompatActivity() { + override fun onCreate(savedInstanceState: Bundle?) { + super.onCreate(savedInstanceState) + // [START maps_android_cloud_based_map_styling] + val mapFragment = MapFragment.newInstance( + GoogleMapOptions() + .mapId(resources.getString(R.string.map_id)) + ) + // [END maps_android_cloud_based_map_styling] + } +} diff --git a/snippets/app/src/gms/java/com/google/maps/example/kotlin/PolylineCustomizationActivity.kt b/snippets/app/src/gms/java/com/google/maps/example/kotlin/PolylineCustomizationActivity.kt new file mode 100644 index 000000000..70ed29951 --- /dev/null +++ b/snippets/app/src/gms/java/com/google/maps/example/kotlin/PolylineCustomizationActivity.kt @@ -0,0 +1,71 @@ +// Copyright 2024 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +package com.google.maps.example.kotlin + +import android.graphics.Color +import androidx.appcompat.app.AppCompatActivity +import com.google.android.gms.maps.GoogleMap +import com.google.android.gms.maps.model.BitmapDescriptorFactory +import com.google.android.gms.maps.model.LatLng +import com.google.android.gms.maps.model.PolylineOptions +import com.google.android.gms.maps.model.StrokeStyle +import com.google.android.gms.maps.model.StyleSpan +import com.google.android.gms.maps.model.TextureStyle +import com.google.maps.example.R + +class PolylineCustomizationActivity : AppCompatActivity() { + private lateinit var map: GoogleMap + + private fun multicoloredPolyline() { + // [START maps_android_polyline_multicolored] + val line = map.addPolyline( + PolylineOptions() + .add(LatLng(47.6677146, -122.3470447), LatLng(47.6442757, -122.2814693)) + .addSpan(StyleSpan(Color.RED)) + .addSpan(StyleSpan(Color.GREEN)) + ) + // [END maps_android_polyline_multicolored] + } + + private fun multicoloredGradientPolyline() { + // [START maps_android_polyline_gradient] + val line = map.addPolyline( + PolylineOptions() + .add(LatLng(47.6677146, -122.3470447), LatLng(47.6442757, -122.2814693)) + .addSpan( + StyleSpan( + StrokeStyle.gradientBuilder( + Color.RED, + Color.YELLOW + ).build() + ) + ) + ) + // [END maps_android_polyline_gradient] + } + + private fun stampedPolyline() { + // [START maps_android_polyline_stamped] + val stampStyle = + TextureStyle.newBuilder(BitmapDescriptorFactory.fromResource(R.drawable.walking_dot)).build() + val span = StyleSpan(StrokeStyle.colorBuilder(Color.RED).stamp(stampStyle).build()) + map.addPolyline( + PolylineOptions() + .add(LatLng(47.6677146, -122.3470447), LatLng(47.6442757, -122.2814693)) + .addSpan(span) + ) + // [END maps_android_polyline_stamped] + } +} diff --git a/snippets/app/src/gms/res/values/strings.xml b/snippets/app/src/gms/res/values/strings.xml new file mode 100644 index 000000000..d05f57ff4 --- /dev/null +++ b/snippets/app/src/gms/res/values/strings.xml @@ -0,0 +1,19 @@ + + + + 13564581852493597319 + diff --git a/tutorials/java/StyledMap/app/build.gradle b/tutorials/java/StyledMap/app/build.gradle index 0a1101100..764eeb5a2 100644 --- a/tutorials/java/StyledMap/app/build.gradle +++ b/tutorials/java/StyledMap/app/build.gradle @@ -23,8 +23,8 @@ android { } } compileOptions { - sourceCompatibility JavaVersion.VERSION_17 - targetCompatibility JavaVersion.VERSION_17 + sourceCompatibility JavaVersion.VERSION_21 + targetCompatibility JavaVersion.VERSION_21 } namespace "com.example.styledmap" } diff --git a/tutorials/kotlin/CurrentPlaceDetailsOnMap/app/build.gradle b/tutorials/kotlin/CurrentPlaceDetailsOnMap/app/build.gradle index 1b02ea19d..3d62c2d98 100644 --- a/tutorials/kotlin/CurrentPlaceDetailsOnMap/app/build.gradle +++ b/tutorials/kotlin/CurrentPlaceDetailsOnMap/app/build.gradle @@ -27,14 +27,13 @@ android { } } compileOptions { - sourceCompatibility JavaVersion.VERSION_17 - targetCompatibility JavaVersion.VERSION_17 + sourceCompatibility JavaVersion.VERSION_21 + targetCompatibility JavaVersion.VERSION_21 } namespace 'com.example.currentplacedetailsonmap' } dependencies { - implementation fileTree(dir: 'libs', include: ['*.jar']) androidTestImplementation('com.android.support.test.espresso:espresso-core:3.0.2', { exclude group: 'com.android.support', module: 'support-annotations' }) diff --git a/tutorials/kotlin/MapWithMarker/app/build.gradle b/tutorials/kotlin/MapWithMarker/app/build.gradle index 00a198aab..c9f75e53e 100644 --- a/tutorials/kotlin/MapWithMarker/app/build.gradle +++ b/tutorials/kotlin/MapWithMarker/app/build.gradle @@ -24,14 +24,13 @@ android { } } compileOptions { - sourceCompatibility JavaVersion.VERSION_17 - targetCompatibility JavaVersion.VERSION_17 + sourceCompatibility JavaVersion.VERSION_21 + targetCompatibility JavaVersion.VERSION_21 } namespace "com.example.mapwithmarker" } dependencies { - implementation fileTree(dir: 'libs', include: ['*.jar']) implementation "androidx.core:core-ktx:1.13.1" implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version" implementation 'androidx.appcompat:appcompat:1.7.0' diff --git a/tutorials/kotlin/Polygons/app/build.gradle b/tutorials/kotlin/Polygons/app/build.gradle index a6903460f..0a593a6af 100644 --- a/tutorials/kotlin/Polygons/app/build.gradle +++ b/tutorials/kotlin/Polygons/app/build.gradle @@ -24,14 +24,13 @@ android { } } compileOptions { - sourceCompatibility JavaVersion.VERSION_17 - targetCompatibility JavaVersion.VERSION_17 + sourceCompatibility JavaVersion.VERSION_21 + targetCompatibility JavaVersion.VERSION_21 } namespace "com.example.polygons" } dependencies { - implementation fileTree(dir: 'libs', include: ['*.jar']) implementation 'androidx.appcompat:appcompat:1.7.0' implementation 'com.google.android.gms:play-services-maps:19.0.0' testImplementation 'junit:junit:4.13.2'