Fix CameraUpdateFactory#zoomOut (#1035)
This commit is contained in:
@@ -10,6 +10,8 @@ MapLibre welcomes participation and contributions from everyone. Please read [`C
|
||||
|
||||
### 🐞 Bug fixes
|
||||
|
||||
* Fix regression in CameraUpdateFactory#zoomOut ([#1035](https://github.com/maplibre/maplibre-gl-native/pull/1035))
|
||||
|
||||
### ⛵ Dependencies
|
||||
|
||||
## 10.0.2 - February 23, 2023
|
||||
|
||||
@@ -7,7 +7,7 @@ import com.mapbox.mapboxsdk.geometry.LatLng
|
||||
import com.mapbox.mapboxsdk.geometry.LatLngBounds
|
||||
import com.mapbox.mapboxsdk.maps.MapboxMap
|
||||
import timber.log.Timber
|
||||
import java.lang.Double.min
|
||||
import java.lang.Double.max
|
||||
import java.util.Arrays
|
||||
|
||||
/**
|
||||
@@ -448,7 +448,7 @@ object CameraUpdateFactory {
|
||||
return when (type) {
|
||||
ZOOM_IN -> currentZoomArg + 1
|
||||
ZOOM_OUT -> {
|
||||
min(currentZoomArg - 1, 0.0)
|
||||
max(currentZoomArg - 1, 0.0)
|
||||
}
|
||||
|
||||
ZOOM_TO -> zoom
|
||||
|
||||
@@ -630,6 +630,7 @@ class OfflineManager private constructor(context: Context) {
|
||||
* @return the single instance of offline manager
|
||||
*/
|
||||
@Synchronized
|
||||
@JvmStatic
|
||||
fun getInstance(context: Context): OfflineManager {
|
||||
if (instance == null) {
|
||||
instance = OfflineManager(context)
|
||||
|
||||
Reference in New Issue
Block a user