diff --git a/app/lib/widget/home_photos.dart b/app/lib/widget/home_photos.dart index 464026cf..770d5fb3 100644 --- a/app/lib/widget/home_photos.dart +++ b/app/lib/widget/home_photos.dart @@ -165,6 +165,7 @@ class _HomePhotosState extends State bottomOffset: _calcBottomAppBarExtent(context), labelTextBuilder: (_) => _buildScrollLabel(context), labelPadding: const EdgeInsets.symmetric(horizontal: 40), + enabled: _isScrollbarVisible, child: ScrollConfiguration( behavior: ScrollConfiguration.of(context) .copyWith(scrollbars: false), @@ -380,10 +381,12 @@ class _HomePhotosState extends State state is ScanAccountDirBlocLoading) { _transformItems(state.files); if (state is ScanAccountDirBlocSuccess) { + _isScrollbarVisible = true; _startupSync(); _tryStartMetadataTask(); } } else if (state is ScanAccountDirBlocFailure) { + _isScrollbarVisible = true; _transformItems(state.files); if (isPageVisible()) { SnackBarManager().showSnackBar(SnackBar( @@ -702,6 +705,8 @@ class _HomePhotosState extends State late final _Web? _web = platform_k.isWeb ? _Web(this) : null; + var _isScrollbarVisible = false; + static final _log = Logger("widget.home_photos._HomePhotosState"); static const _menuValueRefresh = 0; } diff --git a/app/pubspec.lock b/app/pubspec.lock index 3c095456..b159c420 100644 --- a/app/pubspec.lock +++ b/app/pubspec.lock @@ -385,8 +385,8 @@ packages: dependency: "direct main" description: path: "." - ref: "v0.1.0-nc-photos-5" - resolved-ref: a1a34c57a069dc1cffa9759f86ffab2e0c7420ca + ref: "v0.1.0-nc-photos-6" + resolved-ref: c3bb889b421451ef9944f25c55b12bda2f83d5c8 url: "https://gitlab.com/nc-photos/flutter-draggable-scrollbar" source: git version: "0.1.0" diff --git a/app/pubspec.yaml b/app/pubspec.yaml index f89d701d..57fe7f05 100644 --- a/app/pubspec.yaml +++ b/app/pubspec.yaml @@ -44,7 +44,7 @@ dependencies: draggable_scrollbar: git: url: https://gitlab.com/nc-photos/flutter-draggable-scrollbar - ref: v0.1.0-nc-photos-5 + ref: v0.1.0-nc-photos-6 drift: ^1.7.1 equatable: ^2.0.0 event_bus: ^2.0.0