gotoTop method
Goes to the top of the content.
Implementation
ViewportModel gotoTop() {
if (atTop) return this;
final newModel = setYOffset(0);
return newModel.copyWith(
currentHighlightIndex: newModel._findNearestMatch(),
);
}
Goes to the top of the content.
ViewportModel gotoTop() {
if (atTop) return this;
final newModel = setYOffset(0);
return newModel.copyWith(
currentHighlightIndex: newModel._findNearestMatch(),
);
}