Просмотр исходного кода

Revert "Fix the pull down interaction within Image view (#1563)"

This reverts commit 0e26e15cb187374159e927dc8f78e039eb427c64, reversing
changes made to cd320d30dda095ecfd4dba61096d6ace65c2779b.
ashilkn 1 год назад
Родитель
Сommit
28d0e5fee7
2 измененных файлов с 13 добавлено и 12 удалено
  1. 13 11
      lib/ui/viewer/file/zoomable_image.dart
  2. 0 1
      pubspec.yaml

+ 13 - 11
lib/ui/viewer/file/zoomable_image.dart

@@ -104,19 +104,21 @@ class _ZoomableImageState extends State<ZoomableImage>
     } else {
       content = const EnteLoadingWidget();
     }
-    verticalDragCallback(d) => {
-          if (!_isZooming)
-            {
-              if (d.delta.dy > dragSensitivity)
+    final GestureDragUpdateCallback? verticalDragCallback = _isZooming
+        ? null
+        : (d) => {
+              if (!_isZooming)
                 {
-                  {Navigator.of(context).pop()},
-                }
-              else if (d.delta.dy < (dragSensitivity * -1))
-                {
-                  showDetailsSheet(context, widget.photo),
+                  if (d.delta.dy > dragSensitivity)
+                    {
+                      {Navigator.of(context).pop()},
+                    }
+                  else if (d.delta.dy < (dragSensitivity * -1))
+                    {
+                      showDetailsSheet(context, widget.photo),
+                    },
                 },
-            },
-        };
+            };
 
     return GestureDetector(
       onVerticalDragUpdate: verticalDragCallback,

+ 0 - 1
pubspec.yaml

@@ -13,7 +13,6 @@ description: ente photos application
 # https://developer.apple.com/library/archive/documentation/General/Reference/InfoPlistKeyReference/Articles/CoreFoundationKeys.html
 
 version: 0.8.59+579
-
 environment:
   sdk: ">=3.0.0 <4.0.0"