This commit is contained in:
Hamza-Ayed
2024-01-23 00:43:45 +03:00
parent ec7f2de651
commit 8aaca3630d
11 changed files with 125 additions and 71 deletions

View File

@@ -148,39 +148,41 @@ class GoogleMapPassengerWidget extends StatelessWidget {
position: carLocation,
icon: controller.carIcon,
markerId: MarkerId(carLocation.toString())),
Marker(
markerId: MarkerId('MyLocation'.tr),
position: controller.newStartPointLocation,
draggable: true,
icon: controller.startIcon,
infoWindow: const InfoWindow(
title: 'Time',
anchor: Offset(0.5, 0.5), // Adjust the anchor as needed
// snippet: controller.durationFromDriverToPassenger
// .toString(),
),
onDragEnd: (value) {
print(value);
},
// infoWindow: InfoWindow(title: 'my location'.tr),
),
Marker(
markerId: MarkerId('Destination'.tr),
position: controller.newMyLocation,
draggable: true,
icon: controller.endIcon,
infoWindow: InfoWindow(
anchor: const Offset(0.5, 0),
if (controller.isMarkersShown)
Marker(
markerId: MarkerId('MyLocation'.tr),
position: controller.newStartPointLocation,
draggable: true,
icon: controller.startIcon,
infoWindow: const InfoWindow(
title: 'Time',
snippet: controller.durationByPassenger.toString()
anchor: Offset(0.5, 0.5), // Adjust the anchor as needed
// snippet: controller.durationFromDriverToPassenger
// .toString(),
),
onDragEnd: (value) {
print(value);
},
// infoWindow: InfoWindow(title: 'my location'.tr),
),
),
onDragEnd: (value) {
print(value);
},
// infoWindow: InfoWindow(title: 'my location'.tr),
),
if (controller.isMarkersShown)
Marker(
markerId: MarkerId('Destination'.tr),
position: controller.newMyLocation,
draggable: true,
icon: controller.endIcon,
infoWindow: InfoWindow(
anchor: const Offset(0.5, 0),
title: 'Time',
snippet: controller.durationByPassenger.toString()
// snippet: controller.durationFromDriverToPassenger
// .toString(),
),
onDragEnd: (value) {
print(value);
},
// infoWindow: InfoWindow(title: 'my location'.tr),
),
// Marker(
// markerId: MarkerId('Target'.tr),
// position: controller.myDestination,