mirror of
https://gitlab.com/nkming2/nc-photos.git
synced 2025-01-22 08:46:18 +01:00
Fix view exceptions in the new viewer
This commit is contained in:
parent
3576f7e397
commit
03015e999e
2 changed files with 5 additions and 4 deletions
|
@ -163,7 +163,7 @@ class _PageViewState extends State<_PageView> {
|
|||
});
|
||||
} else {
|
||||
WidgetsBinding.instance.addPostFrameCallback((_) {
|
||||
if (mounted) {
|
||||
if (mounted && _scrollController.hasClients) {
|
||||
_scrollController.jumpTo(0);
|
||||
}
|
||||
});
|
||||
|
|
|
@ -87,9 +87,10 @@ class _ZoomableViewerState extends State<ZoomableViewer>
|
|||
}
|
||||
|
||||
void _setIsZooming(bool flag) {
|
||||
setState(() {
|
||||
_isZooming = flag;
|
||||
});
|
||||
_isZooming = flag;
|
||||
if (mounted) {
|
||||
setState(() {});
|
||||
}
|
||||
final next = _isZoomed;
|
||||
if (next != _wasZoomed) {
|
||||
_wasZoomed = next;
|
||||
|
|
Loading…
Reference in a new issue