mirror of
https://github.com/element-hq/element-android
synced 2024-11-28 05:31:21 +03:00
Animate camera while zooming to a user.
This commit is contained in:
parent
372ff9ff97
commit
0f3e4046e1
1 changed files with 6 additions and 4 deletions
|
@ -28,10 +28,12 @@ fun MapboxMap?.zoomToLocation(locationData: LocationData, preserveCurrentZoomLev
|
|||
} else {
|
||||
INITIAL_MAP_ZOOM_IN_PREVIEW
|
||||
}
|
||||
this?.cameraPosition = CameraPosition.Builder()
|
||||
.target(LatLng(locationData.latitude, locationData.longitude))
|
||||
.zoom(zoomLevel)
|
||||
.build()
|
||||
this?.easeCamera {
|
||||
CameraPosition.Builder()
|
||||
.target(LatLng(locationData.latitude, locationData.longitude))
|
||||
.zoom(zoomLevel)
|
||||
.build()
|
||||
}
|
||||
}
|
||||
|
||||
fun MapboxMap?.zoomToBounds(latLngBounds: LatLngBounds) {
|
||||
|
|
Loading…
Reference in a new issue