mirror of
https://github.com/bggRGjQaUbCoE/PiliPlus.git
synced 2026-04-20 11:08:03 +08:00
@@ -662,8 +662,7 @@ class RenderProgressBar extends RenderBox implements MouseTrackerAnnotation {
|
||||
Size computeDryLayout(BoxConstraints constraints) {
|
||||
final desiredWidth = constraints.maxWidth;
|
||||
final desiredHeight = _heightWhenNoLabels();
|
||||
final desiredSize = Size(desiredWidth, desiredHeight);
|
||||
return constraints.constrain(desiredSize);
|
||||
return constraints.constrainDimensions(desiredWidth, desiredHeight);
|
||||
}
|
||||
|
||||
double _heightWhenNoLabels() {
|
||||
|
||||
@@ -185,7 +185,7 @@ class RenderViewPointProgressBar
|
||||
|
||||
@override
|
||||
void performLayout() {
|
||||
size = constraints.constrain(Size(constraints.maxWidth, _barHeight));
|
||||
size = constraints.constrainDimensions(constraints.maxWidth, _barHeight);
|
||||
}
|
||||
|
||||
static const double _barHeight = 15.0;
|
||||
@@ -334,7 +334,6 @@ class BaseRenderProgressBar<T extends BaseSegment> extends RenderBox {
|
||||
BaseRenderProgressBar({
|
||||
required double height,
|
||||
required List<T> segments,
|
||||
ValueSetter<int>? onSeek,
|
||||
}) : _height = height,
|
||||
_segments = segments;
|
||||
|
||||
@@ -356,7 +355,7 @@ class BaseRenderProgressBar<T extends BaseSegment> extends RenderBox {
|
||||
|
||||
@override
|
||||
void performLayout() {
|
||||
size = constraints.constrain(Size(constraints.maxWidth, height));
|
||||
size = constraints.constrainDimensions(constraints.maxWidth, height);
|
||||
}
|
||||
|
||||
@override
|
||||
|
||||
@@ -96,7 +96,7 @@ class RenderProgressBar extends RenderBox {
|
||||
}
|
||||
|
||||
double _radius;
|
||||
double get borderRadius => _radius;
|
||||
double get radius => _radius;
|
||||
set radius(double value) {
|
||||
if (_radius == value) return;
|
||||
_radius = value;
|
||||
@@ -113,7 +113,7 @@ class RenderProgressBar extends RenderBox {
|
||||
|
||||
@override
|
||||
void performLayout() {
|
||||
size = constraints.constrain(Size(constraints.maxWidth, _radius));
|
||||
size = constraints.constrainDimensions(constraints.maxWidth, _radius);
|
||||
}
|
||||
|
||||
@override
|
||||
|
||||
Reference in New Issue
Block a user