Closed AlexandreRoba closed 6 years ago
Hi Alexandre,
I don't understand since I tried to reproduce the issue but with the following code, it works:
class TestPage extends StatefulWidget {
@override
_TestPageState createState() => _TestPageState();
}
class _TestPageState extends State<TestPage> {
double priceRangeLow = 200000.0;
double priceRangeHigh = 300000.0;
@override
Widget build(BuildContext context) {
return Container(
padding: const EdgeInsets.all(15.0),
child: RangeSlider(
lowerValue: priceRangeLow,
upperValue: priceRangeHigh,
max: 1000000.0,
min: 100000.0,
divisions: 19,
showValueIndicator: true,
valueIndicatorMaxDecimals: 0,
onChanged: (double lower, double upper) {
print('$lower / $upper');
},
),
);
}
}
Here is a snapshot:
Maybe could provide a bit more of your code, and especially, focusing on the way you are rendering ?
Thanks
Hi Alexandre,
I have applied to small fix to cover the case where the RangeSlider would be instantiated via ListView.builder()
Hi Didier,
Excellent! That solved the issue. It works like a charm. Thanks for this 👍
Alex
Hi,
I'm trying to use the range slider but I can't seem to move any of the thumb.
This is the code I have dropped on a widget:
I can see the thumbs, they are correclty positionned but I cannot move them? The onChanged is never triggered :( Any idea?
Thanks