providers.dart 467 B

123456789101112131415161718
  1. import 'package:amap_flutter_base/amap_flutter_base.dart';
  2. import 'package:flutter/foundation.dart';
  3. class MyLocationProvider with ChangeNotifier, DiagnosticableTreeMixin {
  4. LatLng _myLatLng;
  5. LatLng get myLatLng => _myLatLng;
  6. void getLocation(double lat,double lng) {
  7. _myLatLng = LatLng(lat, lng);
  8. notifyListeners();
  9. }
  10. @override
  11. void debugFillProperties(DiagnosticPropertiesBuilder properties) {
  12. super.debugFillProperties(properties);
  13. }
  14. }