Skip to content

Commit

Permalink
🐞 Fix: ModalSheetViewControllerLifecycleNotifier.sheetGesture
Browse files Browse the repository at this point in the history
  • Loading branch information
dominicstop committed Sep 27, 2024
1 parent 711ae00 commit 9d5624d
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions ios/Temp/ModalSheetViewControllerLifecycleNotifier.swift
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@ open class ModalSheetViewControllerLifecycleNotifier: ViewControllerLifecycleNot

public override func viewWillAppear(_ animated: Bool) {
super.viewWillAppear(animated);
self.setupSheetGestureIfNeeded();
};

// MARK: - Setup
Expand All @@ -55,14 +56,14 @@ open class ModalSheetViewControllerLifecycleNotifier: ViewControllerLifecycleNot
self.presentationControllerDelegateProxy = self;
};

self._setupSheetGesture();

presentationController.delegate = self;
self._didSetup = true;
};

private func _setupSheetGesture(){
guard let closestSheetPanGesture = self.closestSheetPanGesture else {
public func setupSheetGestureIfNeeded(){
guard self.sheetGesture == nil,
let closestSheetPanGesture = self.closestSheetPanGesture
else {
return;
};

Expand Down

0 comments on commit 9d5624d

Please sign in to comment.