1
0
mirror of https://github.com/immich-app/immich.git synced 2025-08-08 23:07:06 +02:00

fix(mobile): upgrade maplibre_gl package to fix issue with crash in ios7.4 above simulator (#10182)

* fix(mobile): upgrade maplibre_gl package to fix issue with crash in ios7.4 above simulator

* chore: switch from deprecated widget and controller name to new name in latest sdk

* remove todo

---------

Co-authored-by: Alex <alex.tran1502@gmail.com>
This commit is contained in:
Muhideen Mujeeb Adeoye
2024-06-17 23:27:54 +01:00
committed by GitHub
parent c1a5ed3526
commit 99c6fdbc1c
8 changed files with 39 additions and 46 deletions

View File

@ -35,7 +35,7 @@ class MapPage extends HookConsumerWidget {
@override
Widget build(BuildContext context, WidgetRef ref) {
final mapController = useRef<MaplibreMapController?>(null);
final mapController = useRef<MapLibreMapController?>(null);
final markers = useRef<List<MapMarker>>([]);
final markersInBounds = useRef<List<MapMarker>>([]);
final bottomSheetStreamController = useStreamController<MapEvent>();
@ -155,7 +155,7 @@ class MapPage extends HookConsumerWidget {
}
}
void onMapCreated(MaplibreMapController controller) async {
void onMapCreated(MapLibreMapController controller) async {
mapController.value = controller;
controller.addListener(() {
if (controller.isCameraMoving && selectedMarker.value != null) {
@ -373,7 +373,7 @@ class _MapWithMarker extends StatelessWidget {
child: Stack(
children: [
style.widgetWhen(
onData: (style) => MaplibreMap(
onData: (style) => MapLibreMap(
initialCameraPosition:
const CameraPosition(target: LatLng(0, 0)),
styleString: style,
@ -387,7 +387,7 @@ class _MapWithMarker extends StatelessWidget {
tiltGesturesEnabled: false,
dragEnabled: false,
myLocationEnabled: false,
attributionButtonPosition: AttributionButtonPosition.TopRight,
attributionButtonPosition: AttributionButtonPosition.topRight,
rotateGesturesEnabled: false,
),
),