Browse Source

修改设备设置

weicu
tanlongsheng 11 months ago
parent
commit
90baacd0a2
  1. 56
      lib/modules/eq_settings/views/widgets/select_equalizer_widget.dart

56
lib/modules/eq_settings/views/widgets/select_equalizer_widget.dart

@ -85,37 +85,39 @@ class _SelectEqualizerWidgetState extends State<SelectEqualizerWidget> {
children: List.generate( children: List.generate(
_templateData['xAxis'].length, _templateData['xAxis'].length,
(index) => Expanded( (index) => Expanded(
child: Column( child: Stack(
children: [ children: [
Expanded( RotatedBox(
child: RotatedBox( quarterTurns: 3,
quarterTurns: 3, child: StatefulBuilder(
child: StatefulBuilder( builder: (BuildContext context, setStateful) {
builder: (BuildContext context, setStateful) { return Slider(
return Slider( value: _values[index].toDouble(),
value: _values[index].toDouble(), min: -5,
min: -5, max: 5,
max: 5, divisions: 10,
divisions: 10, activeColor: Colors.green,
activeColor: Colors.green, onChanged: (value) {
onChanged: (value) { setStateful(() {
setStateful(() { _values[index] = value.toInt();
_values[index] = value.toInt(); });
}); },
}, onChangeEnd: (value) {
onChangeEnd: (value) { setState(() {});
setState(() {}); },
}, );
); },
},
),
), ),
), ),
Text( Align(
_templateData['xAxis'][index], alignment: Alignment.bottomCenter,
style: TextStyle( child: Text(
_templateData['xAxis'][index],
style: TextStyle(
fontSize: 14.sp, fontSize: 14.sp,
color: isDarkMode ? Colors.white : Colors.grey), color: isDarkMode ? Colors.white : Colors.grey,
),
),
), ),
], ],
), ),

Loading…
Cancel
Save