mirror of
https://github.com/flutter/samples.git
synced 2025-11-08 13:58:47 +00:00
Update place_tracker README (#530)
This commit is contained in:
@@ -1,11 +1,10 @@
|
|||||||
# Place Tracker
|
# Place Tracker
|
||||||
|
|
||||||
A sample place tracking app that uses the [google_maps_flutter](https://github.com/flutter/plugins/tree/master/packages/google_maps_flutter) plugin.
|
A sample place tracking app that uses the
|
||||||
Keep track of your favorite places, places you've visited, and places you want to go. View details
|
[google_maps_flutter](https://github.com/flutter/plugins/tree/master/packages/google_maps_flutter)
|
||||||
about these places, show them on a map, and get directions to them.
|
plugin. Keep track of your favorite places, places you've visited, and places
|
||||||
|
you want to go. View details about these places, show them on a map, and get
|
||||||
**This sample is not currently in a finished state. We're in the process
|
directions to them.
|
||||||
of building it out. This sample currently only works on Android (see Caveat below).**
|
|
||||||
|
|
||||||
## Goals
|
## Goals
|
||||||
|
|
||||||
@@ -34,6 +33,7 @@ To run this sample app, you will need an API key.
|
|||||||
|
|
||||||
Get an API key at <https://cloud.google.com/maps-platform/>.
|
Get an API key at <https://cloud.google.com/maps-platform/>.
|
||||||
|
|
||||||
|
### Android
|
||||||
Specify your API key in the application manifest
|
Specify your API key in the application manifest
|
||||||
`android/app/src/main/AndroidManifest.xml`:
|
`android/app/src/main/AndroidManifest.xml`:
|
||||||
|
|
||||||
@@ -44,6 +44,23 @@ Specify your API key in the application manifest
|
|||||||
android:value="YOUR KEY HERE"/>
|
android:value="YOUR KEY HERE"/>
|
||||||
```
|
```
|
||||||
|
|
||||||
|
### iOS
|
||||||
|
Specify your API key in `AppDelegate.swift`:
|
||||||
|
|
||||||
|
```swift
|
||||||
|
@UIApplicationMain
|
||||||
|
@objc class AppDelegate: FlutterAppDelegate {
|
||||||
|
override func application(
|
||||||
|
_ application: UIApplication,
|
||||||
|
didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]?
|
||||||
|
) -> Bool {
|
||||||
|
GMSServices.provideAPIKey("YOUR API KEY HERE")
|
||||||
|
GeneratedPluginRegistrant.register(with: self)
|
||||||
|
return super.application(application, didFinishLaunchingWithOptions: launchOptions)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
For additional help setting up the plugin, see the plugin's
|
For additional help setting up the plugin, see the plugin's
|
||||||
[README](https://pub.dev/packages/google_maps_flutter)
|
[README](https://pub.dev/packages/google_maps_flutter)
|
||||||
page.
|
page.
|
||||||
@@ -55,13 +72,6 @@ For help getting started with Flutter, view our online
|
|||||||
|
|
||||||
The google_maps_flutter plugin is in developer preview until [dynamic thread
|
The google_maps_flutter plugin is in developer preview until [dynamic thread
|
||||||
merging](https://github.com/flutter/flutter/projects/155) is finished.
|
merging](https://github.com/flutter/flutter/projects/155) is finished.
|
||||||
* Dart APIs for controlling and interacting with a GoogleMap view from Flutter
|
|
||||||
code are still being consolidated and expanded. The intention is to grow
|
|
||||||
current coverage into a complete offering. Issues and pull requests aimed to
|
|
||||||
help us prioritize and speed up this effort are very welcome.
|
|
||||||
* Currently the plugin only supports Android as it embeds a platform view in the
|
|
||||||
Flutter hierarchy which is currently only supported for Android ([tracking
|
|
||||||
issue](https://github.com/flutter/flutter/issues/19030)).
|
|
||||||
|
|
||||||
## Questions/issues
|
## Questions/issues
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user