Skip to content
This repository has been archived by the owner on Feb 17, 2020. It is now read-only.

Commit

Permalink
Adjusting content offset based on content inset.
Browse files Browse the repository at this point in the history
  • Loading branch information
benguild committed Dec 6, 2018
1 parent a7ce81e commit 746d54d
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion PullToDismissTransition.podspec
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Pod::Spec.new do |s|
s.name = "PullToDismissTransition"
s.version = "0.7.4"
s.version = "0.7.5"
s.homepage = "https://github.com/benguild/PullToDismissTransition"
s.summary = "(Beta) Uses `UIPercentDrivenInteractiveTransition` and `UIViewControllerAnimatedTransitioning` to quickly implement nice “pull-to-dismiss” interactions on modal view controller(s). — Also handles `UIScrollView` bounce toggling dynamically when necessary. "
s.license = 'MIT'
Expand Down
4 changes: 2 additions & 2 deletions PullToDismissTransition.swift
Original file line number Diff line number Diff line change
Expand Up @@ -225,8 +225,8 @@ public class PullToDismissTransition: UIPercentDrivenInteractiveTransition {

if let monitoredScrollView = monitoredScrollView, monitoredScrollView.isScrollEnabled {
monitoredScrollView.contentOffset = CGPoint(
x: monitoredScrollView.contentOffset.x,
y: 0
x: monitoredScrollView.contentOffset.x - monitoredScrollView.contentInset.left,
y: -monitoredScrollView.contentInset.top
)
}

Expand Down

0 comments on commit 746d54d

Please sign in to comment.