mirror of
https://github.com/immich-app/immich
synced 2025-11-14 17:36:12 +00:00
fix(mobile): double swipe (#18749)
debug: double swipe issue Co-authored-by: shenlong-tanwen <139912620+shalong-tanwen@users.noreply.github.com>
This commit is contained in:
parent
0e81c20cbb
commit
44d49b9671
2 changed files with 6 additions and 6 deletions
|
|
@ -1,5 +1,4 @@
|
|||
import 'package:flutter/widgets.dart';
|
||||
|
||||
import 'package:immich_mobile/widgets/photo_view/src/controller/photo_view_controller_delegate.dart'
|
||||
show PhotoViewControllerDelegate;
|
||||
|
||||
|
|
@ -7,7 +6,7 @@ mixin HitCornersDetector on PhotoViewControllerDelegate {
|
|||
HitCorners _hitCornersX() {
|
||||
final double childWidth = scaleBoundaries.childSize.width * scale;
|
||||
final double screenWidth = scaleBoundaries.outerSize.width;
|
||||
if (screenWidth >= childWidth) {
|
||||
if (screenWidth - childWidth > -0.001) {
|
||||
return const HitCorners(true, true);
|
||||
}
|
||||
final x = -position.dx;
|
||||
|
|
@ -18,7 +17,7 @@ mixin HitCornersDetector on PhotoViewControllerDelegate {
|
|||
HitCorners _hitCornersY() {
|
||||
final double childHeight = scaleBoundaries.childSize.height * scale;
|
||||
final double screenHeight = scaleBoundaries.outerSize.height;
|
||||
if (screenHeight >= childHeight) {
|
||||
if (screenHeight - childHeight > -0.001) {
|
||||
return const HitCorners(true, true);
|
||||
}
|
||||
final y = -position.dy;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue