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;
|
||||
$country = filterRequest("country");
|
||||
|
||||
$startNameAddress = filterRequest("startNameAddress");
|
||||
$endNameAddress = filterRequest("endNameAddress");
|
||||
$startNameAddress = (string)(filterRequest("startNameAddress") ?? '');
|
||||
$endNameAddress = (string)(filterRequest("endNameAddress") ?? '');
|
||||
$destLat = (float) filterRequest("destLat");
|
||||
$destLng = (float) filterRequest("destLng");
|
||||
$passengerLat = (float) filterRequest("passengerLat");
|
||||
|
||||
@@ -467,7 +467,7 @@ class LocationController extends GetxController with WidgetsBindingObserver {
|
||||
// In LocationController.dart
|
||||
|
||||
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? storedPassengerId = box.read(BoxName.passengerID);
|
||||
String? storedRideId = box.read(BoxName.rideId);
|
||||
|
||||
@@ -208,10 +208,10 @@ class MapEngineController extends GetxController {
|
||||
|
||||
int? _getImageSize(String id) {
|
||||
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;
|
||||
if (ratio == 0) ratio = 3.0; // fallback just in case
|
||||
return (120 * ratio).toInt();
|
||||
return (48 * ratio).toInt();
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
@@ -322,11 +322,11 @@ class NearbyDriversController extends GetxController {
|
||||
|
||||
String _getIconForCar(Map<String, dynamic> carData) {
|
||||
if (carData['model'].toString().contains('دراجة')) {
|
||||
return 'assets/images/moto.png';
|
||||
return 'moto_icon';
|
||||
} else if (carData['gender'] == 'Female') {
|
||||
return 'assets/images/lady.png';
|
||||
return 'lady_icon';
|
||||
} else {
|
||||
return 'assets/images/car.png';
|
||||
return 'car_icon';
|
||||
}
|
||||
}
|
||||
|
||||
@@ -350,7 +350,7 @@ class NearbyDriversController extends GetxController {
|
||||
markerId: mId,
|
||||
position: newPosition,
|
||||
rotation: newHeading,
|
||||
icon: InlqBitmap.fromAsset(icon),
|
||||
icon: InlqBitmap.fromStyleImage(icon),
|
||||
anchor: const Offset(0.5, 0.5),
|
||||
),
|
||||
};
|
||||
@@ -398,7 +398,7 @@ class NearbyDriversController extends GetxController {
|
||||
final updatedMarker = oldMarker.copyWith(
|
||||
position: currentPos,
|
||||
rotation: currentHeading,
|
||||
icon: InlqBitmap.fromAsset(icon),
|
||||
icon: InlqBitmap.fromStyleImage(icon),
|
||||
);
|
||||
|
||||
mapEngine.markers = {
|
||||
|
||||
Reference in New Issue
Block a user