added current location marker
This commit is contained in:
@ -5,15 +5,22 @@ import 'package:latlong2/latlong.dart';
|
||||
|
||||
class MapState extends ChangeNotifier {
|
||||
bool _isCurrentlyLoading = false;
|
||||
LatLng? _currentLocation;
|
||||
LatLng? _activeMarker;
|
||||
final MapController _mapController = MapController();
|
||||
final Geolocator _geolocator = Geolocator();
|
||||
|
||||
bool get isCurrentlyLoading => _isCurrentlyLoading;
|
||||
LatLng? get getCurrentLocation => _currentLocation;
|
||||
LatLng? get getActiveMarker => _activeMarker;
|
||||
MapController get getMapController => _mapController;
|
||||
Geolocator get getGeolocator => _geolocator;
|
||||
|
||||
void setCurrentLocation(LatLng? currentLocation) {
|
||||
_currentLocation = currentLocation;
|
||||
notifyListeners();
|
||||
}
|
||||
|
||||
void setActiveMarker(LatLng? marker) {
|
||||
_activeMarker = marker;
|
||||
notifyListeners();
|
||||
|
Reference in New Issue
Block a user