CScrollbar constructor
const
CScrollbar({
- Key? key,
- required Widget child,
- ScrollController? controller,
- bool isAlwaysShown = false,
- double thickness = defaultThickness,
- double thicknessWhileDragging = defaultThicknessWhileDragging,
- Radius radius = defaultRadius,
- Radius radiusWhileDragging = defaultRadiusWhileDragging,
- Color color = Colors.grey,
- ScrollNotificationPredicate? notificationPredicate,
Creates an iOS style scrollbar that wraps the given child.
The child should be a source of ScrollNotification notifications,
typically a Scrollable widget.
Implementation
const CScrollbar({
Key? key,
required Widget child,
ScrollController? controller,
bool isAlwaysShown = false,
double thickness = defaultThickness,
this.thicknessWhileDragging = defaultThicknessWhileDragging,
Radius radius = defaultRadius,
this.radiusWhileDragging = defaultRadiusWhileDragging,
this.color = Colors.grey,
ScrollNotificationPredicate? notificationPredicate,
}) :
assert(thickness < double.infinity),
assert(thicknessWhileDragging < double.infinity),
super(
key: key,
child: child,
controller: controller,
isAlwaysShown: isAlwaysShown,
thickness: thickness,
radius: radius,
fadeDuration: _kScrollbarFadeDuration,
timeToFade: _kScrollbarTimeToFade,
pressDuration: const Duration(milliseconds: 100),
notificationPredicate:
notificationPredicate ?? defaultScrollNotificationPredicate,
);