_scrollController ..addListener(() { final triggerFetchMoreSize = 0.7 * _scrollController.position.maxScrollExtent;
if (_scrollController.position.pixels > triggerFetchMoreSize) {
if (hasMore &&
currentEndPosition < currentCount &&
!loading &&
!inErrorState) {
setState(() {
loading = true;
currentStartPosition = currentEndPosition;
currentEndPosition =
min(currentStartPosition + pageCount, currentCount);
});
}
}
});