[shuttle]
[视角切换]
This commit is contained in:
yangyakun
2023-11-27 18:17:37 +08:00
parent 868a0f7947
commit 3b9dc99ed4

View File

@@ -9,6 +9,7 @@ import android.widget.RelativeLayout
import androidx.lifecycle.ViewModelProvider
import androidx.lifecycle.findViewTreeViewModelStoreOwner
import com.amap.api.maps.AMap
import com.amap.api.maps.CameraUpdateFactory
import com.amap.api.maps.TextureMapView
import com.amap.api.maps.model.BitmapDescriptor
import com.amap.api.maps.model.BitmapDescriptorFactory
@@ -190,15 +191,15 @@ class BusPassengerMapDirectionView @JvmOverloads constructor(
boundsBuilder.include(it)
}
boundsBuilder.include(currentLatLng)
// mAMap.moveCamera(
// CameraUpdateFactory.newLatLngBoundsRect(
// boundsBuilder.build(),
// 100,
// 100,
// 100,
// 100
// )
// )
mAMap.moveCamera(
CameraUpdateFactory.newLatLngBoundsRect(
boundsBuilder.build(),
100,
100,
100,
100
)
)
} catch (e: Exception) {
e.printStackTrace()
}