Update: 2026-07-23 00:11:36
This commit is contained in:
@@ -8,8 +8,8 @@ $passenger_id = filterRequest("passenger_id");
|
|||||||
$promo_code_id = filterRequest("promo_code_id") ? filterRequest("promo_code_id") : 0;
|
$promo_code_id = filterRequest("promo_code_id") ? filterRequest("promo_code_id") : 0;
|
||||||
$country = filterRequest("country");
|
$country = filterRequest("country");
|
||||||
|
|
||||||
$startNameAddress = filterRequest("startNameAddress");
|
$startNameAddress = (string)(filterRequest("startNameAddress") ?? '');
|
||||||
$endNameAddress = filterRequest("endNameAddress");
|
$endNameAddress = (string)(filterRequest("endNameAddress") ?? '');
|
||||||
$destLat = (float) filterRequest("destLat");
|
$destLat = (float) filterRequest("destLat");
|
||||||
$destLng = (float) filterRequest("destLng");
|
$destLng = (float) filterRequest("destLng");
|
||||||
$passengerLat = (float) filterRequest("passengerLat");
|
$passengerLat = (float) filterRequest("passengerLat");
|
||||||
|
|||||||
@@ -467,7 +467,7 @@ class LocationController extends GetxController with WidgetsBindingObserver {
|
|||||||
// In LocationController.dart
|
// In LocationController.dart
|
||||||
|
|
||||||
void emitLocationToSocket(LatLng pos, double head, double spd) {
|
void emitLocationToSocket(LatLng pos, double head, double spd) {
|
||||||
String status = box.read(BoxName.statusDriverLocation) ?? 'on';
|
String status = box.read(BoxName.statusDriverLocation) ?? 'off';
|
||||||
String? currentRideStatus = box.read(BoxName.rideStatus);
|
String? currentRideStatus = box.read(BoxName.rideStatus);
|
||||||
String? storedPassengerId = box.read(BoxName.passengerID);
|
String? storedPassengerId = box.read(BoxName.passengerID);
|
||||||
String? storedRideId = box.read(BoxName.rideId);
|
String? storedRideId = box.read(BoxName.rideId);
|
||||||
|
|||||||
@@ -208,10 +208,10 @@ class MapEngineController extends GetxController {
|
|||||||
|
|
||||||
int? _getImageSize(String id) {
|
int? _getImageSize(String id) {
|
||||||
if (id == carIcon || id == motoIcon || id == ladyIcon) {
|
if (id == carIcon || id == motoIcon || id == ladyIcon) {
|
||||||
// Scale based on pixel ratio so it's not tiny on iOS Retina displays
|
// Scale based on pixel ratio (48dp for standard sleek car markers)
|
||||||
double ratio = ui.window.devicePixelRatio;
|
double ratio = ui.window.devicePixelRatio;
|
||||||
if (ratio == 0) ratio = 3.0; // fallback just in case
|
if (ratio == 0) ratio = 3.0; // fallback just in case
|
||||||
return (120 * ratio).toInt();
|
return (48 * ratio).toInt();
|
||||||
}
|
}
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -322,11 +322,11 @@ class NearbyDriversController extends GetxController {
|
|||||||
|
|
||||||
String _getIconForCar(Map<String, dynamic> carData) {
|
String _getIconForCar(Map<String, dynamic> carData) {
|
||||||
if (carData['model'].toString().contains('دراجة')) {
|
if (carData['model'].toString().contains('دراجة')) {
|
||||||
return 'assets/images/moto.png';
|
return 'moto_icon';
|
||||||
} else if (carData['gender'] == 'Female') {
|
} else if (carData['gender'] == 'Female') {
|
||||||
return 'assets/images/lady.png';
|
return 'lady_icon';
|
||||||
} else {
|
} else {
|
||||||
return 'assets/images/car.png';
|
return 'car_icon';
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -350,7 +350,7 @@ class NearbyDriversController extends GetxController {
|
|||||||
markerId: mId,
|
markerId: mId,
|
||||||
position: newPosition,
|
position: newPosition,
|
||||||
rotation: newHeading,
|
rotation: newHeading,
|
||||||
icon: InlqBitmap.fromAsset(icon),
|
icon: InlqBitmap.fromStyleImage(icon),
|
||||||
anchor: const Offset(0.5, 0.5),
|
anchor: const Offset(0.5, 0.5),
|
||||||
),
|
),
|
||||||
};
|
};
|
||||||
@@ -398,7 +398,7 @@ class NearbyDriversController extends GetxController {
|
|||||||
final updatedMarker = oldMarker.copyWith(
|
final updatedMarker = oldMarker.copyWith(
|
||||||
position: currentPos,
|
position: currentPos,
|
||||||
rotation: currentHeading,
|
rotation: currentHeading,
|
||||||
icon: InlqBitmap.fromAsset(icon),
|
icon: InlqBitmap.fromStyleImage(icon),
|
||||||
);
|
);
|
||||||
|
|
||||||
mapEngine.markers = {
|
mapEngine.markers = {
|
||||||
|
|||||||
Reference in New Issue
Block a user