icons worked
This commit is contained in:
parent
c8223d9b7d
commit
de6a7f2399
@ -317,9 +317,38 @@ class _MapboxPagesState extends State<MapboxPages> with ShowErrorDialog {
|
||||
actions: [
|
||||
DropdownButton<String>(
|
||||
value: selectedMode,
|
||||
items: ['walking', 'cycling', 'driving'].map((mode) {
|
||||
return DropdownMenuItem(value: mode, child: Text(mode));
|
||||
}).toList(),
|
||||
items: [
|
||||
DropdownMenuItem(
|
||||
value: 'walking',
|
||||
child: Row(
|
||||
children: [
|
||||
Icon(Icons.directions_walk, color: Colors.blue),
|
||||
SizedBox(width: 8),
|
||||
Text('Walking'),
|
||||
],
|
||||
),
|
||||
),
|
||||
DropdownMenuItem(
|
||||
value: 'cycling',
|
||||
child: Row(
|
||||
children: [
|
||||
Icon(Icons.directions_bike, color: Colors.green),
|
||||
SizedBox(width: 8),
|
||||
Text('Cycling'),
|
||||
],
|
||||
),
|
||||
),
|
||||
DropdownMenuItem(
|
||||
value: 'driving',
|
||||
child: Row(
|
||||
children: [
|
||||
Icon(Icons.directions_car, color: Colors.red),
|
||||
SizedBox(width: 8),
|
||||
Text('Driving'),
|
||||
],
|
||||
),
|
||||
),
|
||||
],
|
||||
onChanged: (mode) {
|
||||
setState(() {
|
||||
selectedMode = mode!;
|
||||
|
Loading…
x
Reference in New Issue
Block a user