This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/// Помощник с логикой пагинации | |
class PaginationHelper<T> { | |
static const double _defaultPaginationOffset = 50; | |
/// Смещение от конца прокрутки после которого начинать пагинацию | |
double paginationOffset; | |
/// Контроллер прокрутки | |
ScrollController scrollController; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/// Билдер [WidgetModel] для экрана Дэшборда [DashboardScreen] | |
DashboardWidgetModel createDashboardScreenWm(BuildContext context) { | |
final component = Injector.of<DashboardScreenComponent>(context).component; | |
final dependencies = WidgetModelDependencies( | |
errorHandler: StandardErrorHandler( | |
component.messageController, | |
component.dialogController, | |
component.sessionInteractor, | |
component.authInteractor, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
///Базовый класс для обработки ошибок, связанных с сервисным слоем | |
abstract class NetworkErrorHandler implements ErrorHandler { | |
@override | |
void handleError(Object error) { | |
Object e; | |
bool isSilent = false; | |
bool isOverlayed = false; | |
if (error is SilentException) { | |
e = error.originalError; |