Skip to content

Commit

Permalink
Disallow interrupting the panel interaction while bouncing over the m…
Browse files Browse the repository at this point in the history
…ost expanded state (#652)

I decided to disallow interrupting panel interactions while bouncing over the most expanded state in order to fix the 2nd issue in #633, #633 (comment).
  • Loading branch information
scenee authored Nov 9, 2024
1 parent b6e8928 commit b0fd0d4
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Sources/Core.swift
Original file line number Diff line number Diff line change
Expand Up @@ -561,7 +561,7 @@ class Core: NSObject, UIGestureRecognizerDelegate {
}

private func interruptAnimationIfNeeded() {
if let animator = self.moveAnimator, animator.isRunning {
if let animator = self.moveAnimator, animator.isRunning, 0 <= layoutAdapter.offsetFromMostExpandedAnchor {
os_log(msg, log: devLog, type: .debug, "the attraction animator interrupted!!!")
animator.stopAnimation(true)
endAttraction(false)
Expand Down

0 comments on commit b0fd0d4

Please sign in to comment.