showTraffic method

Future showTraffic (bool enable)

显示路况信息

Implementation

Future showTraffic(bool enable) {
  return platform(
    android: (pool) async {
      final map = await androidController.getMap();
      await map.setTrafficEnabled(enable);

      pool..add(map);
    },
    ios: (pool) async {
      await iosController.set_showTraffic(enable);
    },
  );
}