flutter_tenc_map

腾讯地图定位

![pub package]

android:配置地图Key

在AndroidManifest.xml中配置

    <application
            ...
        <meta-data
            android:name="TencentMapSDK"
            android:value="H5PBZ-PNV3V-F2WPG-UUZCN-O6MPQ-LLB3Q" />
            ...
    </application>
value为腾讯地图的KEY值

使用方法

1.导入包

import 'package:flutter_tenc_map/flutter_tenc_map.dart';

使用前初始化

FlutterTencMap.init("");

3.请求定位

  Location location = await FlutterTencMap.getLocation(1000);

参数为多久请求一次,默认10000毫秒

4.添加定位监听

   FlutterTencMap.locationController.listener.add((location) {
        //work
      });

5.停止定位

  bool isOK = await FlutterTencMap.stopLocation();

Libraries

flutter_tenc_map
location
location_controller
map_view
my_location_style
tag_tip

Dart

VM

dart:ffi
Foreign Function Interface for interoperability with the C programming language. [...]

Web

dart:html
HTML elements and other resources for web-based applications that need to interact with the browser and the DOM (Document Object Model). [...]
dart:js
Low-level support for interoperating with JavaScript. [...]
dart:js_util
Utility methods to efficiently manipulate typed JSInterop objects in cases where the name to call is not known at runtime. You should only use these methods when the same effect cannot be achieved with @JS annotations. These methods would be extension methods on JSObject if Dart supported extension methods.