mirror of
https://gitlab.com/nkming2/nc-photos.git
synced 2025-02-08 18:28:53 +01:00
(Web) Hide scrollbar in viewer
This commit is contained in:
parent
afaf432ab0
commit
ef41e4516c
1 changed files with 44 additions and 40 deletions
|
@ -226,6 +226,8 @@ class _ViewerState extends State<Viewer>
|
||||||
widthFactor: 1 / _viewportFraction,
|
widthFactor: 1 / _viewportFraction,
|
||||||
child: NotificationListener<ScrollNotification>(
|
child: NotificationListener<ScrollNotification>(
|
||||||
onNotification: (notif) => _onPageContentScrolled(notif, index),
|
onNotification: (notif) => _onPageContentScrolled(notif, index),
|
||||||
|
child: ScrollConfiguration(
|
||||||
|
behavior: ScrollConfiguration.of(context).copyWith(scrollbars: false),
|
||||||
child: SingleChildScrollView(
|
child: SingleChildScrollView(
|
||||||
controller: _pageStates[index]!.scrollController,
|
controller: _pageStates[index]!.scrollController,
|
||||||
physics: !_isZoomed ? null : const NeverScrollableScrollPhysics(),
|
physics: !_isZoomed ? null : const NeverScrollableScrollPhysics(),
|
||||||
|
@ -250,10 +252,11 @@ class _ViewerState extends State<Viewer>
|
||||||
minHeight: MediaQuery.of(context).size.height),
|
minHeight: MediaQuery.of(context).size.height),
|
||||||
decoration: BoxDecoration(
|
decoration: BoxDecoration(
|
||||||
color: Theme.of(context).scaffoldBackgroundColor,
|
color: Theme.of(context).scaffoldBackgroundColor,
|
||||||
borderRadius:
|
borderRadius: const BorderRadius.vertical(
|
||||||
const BorderRadius.vertical(top: Radius.circular(4)),
|
top: Radius.circular(4)),
|
||||||
),
|
),
|
||||||
margin: EdgeInsets.only(top: _calcDetailPaneOffset(index)),
|
margin:
|
||||||
|
EdgeInsets.only(top: _calcDetailPaneOffset(index)),
|
||||||
// this visibility widget avoids loading the detail pane
|
// this visibility widget avoids loading the detail pane
|
||||||
// until it's actually opened, otherwise swiping between
|
// until it's actually opened, otherwise swiping between
|
||||||
// photos will slow down severely
|
// photos will slow down severely
|
||||||
|
@ -273,6 +276,7 @@ class _ViewerState extends State<Viewer>
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
|
),
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue