Refactor. Fires marker calibration
This commit is contained in:
parent
574c1afc33
commit
f970c6b4fe
9 changed files with 128 additions and 51 deletions
27
lib/fireMarkerIcon.dart
Normal file
27
lib/fireMarkerIcon.dart
Normal file
|
|
@ -0,0 +1,27 @@
|
|||
import 'package:flutter/material.dart';
|
||||
import 'fireMarkType.dart';
|
||||
import 'colors.dart';
|
||||
|
||||
class FireMarkerIcon extends StatelessWidget {
|
||||
|
||||
final FireMarkType type;
|
||||
|
||||
FireMarkerIcon(this.type);
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
switch (type) {
|
||||
case FireMarkType.position:
|
||||
return new Icon(Icons.location_on, color: fires600, size: 50.0);
|
||||
case FireMarkType.pixel:
|
||||
return new Icon(Icons.brightness_1, color: fires900, size: 3.0);
|
||||
case FireMarkType.fire:
|
||||
return new Image.asset('images/fire-marker-l.png');
|
||||
case FireMarkType.industry:
|
||||
return new Image.asset('images/industry-marker-reg.png');
|
||||
case FireMarkType.falsePos:
|
||||
default:
|
||||
return new Image.asset('images/industry-marker.png');
|
||||
}
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue