You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit 6210c6d
Browse filesBrowse the repository at this point in the historyBrowse files
fix(tutorials): migrate CurrentPlaceDetailsOnMap to Places SDK 6 (#2456)
Places SDK for Android 6.0 removed Places.initialize and
PlacesClient.findCurrentPlace, which both CurrentPlaceDetailsOnMap
tutorials relied on. Use Places.initializeWithNewPlacesApiEnabled and
searchNearby around the device's last-known location instead.
The tutorials were not part of the root build, so the breakage went
unnoticed. Include them in settings.gradle.kts, the build-tutorials CI
job and verify_all.sh, and fix the build files so they compile with the
shared version catalog and current AGP.
Copy file name to clipboardExpand all lines: tutorials/java/CurrentPlaceDetailsOnMap/README.md
+12-1Lines changed: 12 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -7,7 +7,7 @@ This sample goes hand in hand with a tutorial for the Google Maps Android API:
7
7
Prerequisites
8
8
--------------
9
9
10
-
- Android API level 21+
10
+
- Android API level 24+
11
11
- Latest Android Build Tools
12
12
- Android Support Repository
13
13
- Google Repository
@@ -28,6 +28,17 @@ This sample uses the Gradle build system.
28
28
29
29
This demo app requires that you add your own Google Maps API key. See [Get an API key](https://developers.google.com/maps/documentation/android-sdk/get-api-key) for more instructions.
30
30
31
+
The app uses the Places SDK for Android (New), so the API key must have
32
+
[Places API (New)](https://developers.google.com/maps/documentation/places/android-sdk/cloud-setup)
33
+
enabled in addition to the Maps SDK for Android.
34
+
35
+
This sample is part of the root Gradle build. From the root of this repository, add your key to
36
+
`secrets.properties` (see `local.defaults.properties` for the format) and run:
Copy file name to clipboardExpand all lines: tutorials/java/CurrentPlaceDetailsOnMap/app/src/main/java/com/example/currentplacedetailsonmap/MapsActivityCurrentPlace.java
Copy file name to clipboardExpand all lines: tutorials/kotlin/CurrentPlaceDetailsOnMap/README.md
+12-1Lines changed: 12 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -7,7 +7,7 @@ This sample goes hand in hand with a tutorial for the Google Maps Android API:
7
7
Prerequisites
8
8
--------------
9
9
10
-
- Android API level 21+
10
+
- Android API level 24+
11
11
- Latest Android Build Tools
12
12
13
13
Getting started
@@ -25,6 +25,17 @@ This sample uses the Gradle build system.
25
25
26
26
This demo app requires that you add your own Google Maps API key. See [Get an API key](https://developers.google.com/maps/documentation/android-sdk/get-api-key) for more instructions.
27
27
28
+
The app uses the Places SDK for Android (New), so the API key must have
29
+
[Places API (New)](https://developers.google.com/maps/documentation/places/android-sdk/cloud-setup)
30
+
enabled in addition to the Maps SDK for Android.
31
+
32
+
This sample is part of the root Gradle build. From the root of this repository, add your key to
33
+
`secrets.properties` (see `local.defaults.properties` for the format) and run:
Copy file name to clipboardExpand all lines: tutorials/kotlin/CurrentPlaceDetailsOnMap/app/src/main/java/com/example/currentplacedetailsonmap/MapsActivityCurrentPlace.kt
0 commit comments