toScrollDirection function
Implementation
ScrollDirection toScrollDirection(int? index) {
switch (index) {
case 0:
return ScrollDirection.horizontal;
case 1:
return ScrollDirection.vertical;
}
return ScrollDirection.unknown;
}