Remove double parsing in map
This commit is contained in:
parent
859e0b0c89
commit
f476a099f8
1 changed files with 3 additions and 3 deletions
|
|
@ -388,19 +388,19 @@ class _genericMapState extends State<genericMap> {
|
|||
falsePosList.forEach((falsePos) {
|
||||
var coords = falsePos['geo']['coordinates'];
|
||||
// print('false pos: ${coords}');
|
||||
var loc = LatLng(double.parse(coords[1]), double.parse(coords[0]));
|
||||
var loc = LatLng(coords[1], coords[0]);
|
||||
markers.add(FireMarker(loc, FireMarkType.falsePos));
|
||||
if (calibrate) markers.add(FireMarker(loc, FireMarkType.pixel));
|
||||
});
|
||||
industries.forEach((industry) {
|
||||
// print(fire['geo']['coordinates']);
|
||||
var coords = industry['geo']['coordinates'];
|
||||
var loc = LatLng(double.parse(coords[1]), double.parse(coords[0]));
|
||||
var loc = LatLng(coords[1], coords[0]);
|
||||
markers.add(FireMarker(loc, FireMarkType.industry));
|
||||
if (calibrate) markers.add(FireMarker(loc, FireMarkType.pixel));
|
||||
});
|
||||
fires.forEach((fire) {
|
||||
var loc = new LatLng(double.parse(fire['lat']), double.parse(fire['lon']));
|
||||
var loc = new LatLng(fire['lat'], fire['lon']);
|
||||
markers.add(
|
||||
FireMarker(loc, FireMarkType.fire, () => print('marker pressed')));
|
||||
markers.add(FireMarker(loc, FireMarkType.pixel));
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue