Merge pull request #52 from futuretap/master

Fixed infinite recursion in FloatingPanel.responds(to:)
This commit is contained in:
Shin Yamamoto authored and GitHub committed 2018-11-16 10:25:34 +09:00
commit eaf0ebe62b
1 file changed
+4 -2
@@ -344,8 +344,10 @@ public class FloatingPanelController: UIViewController, UIScrollViewDelegate, UI
///
public func track(scrollView: UIScrollView) {
floatingPanel.scrollView = scrollView
floatingPanel.userScrollViewDelegate = scrollView.delegate
scrollView.delegate = floatingPanel
if scrollView.delegate !== floatingPanel {
floatingPanel.userScrollViewDelegate = scrollView.delegate
scrollView.delegate = floatingPanel
}
switch contentInsetAdjustmentBehavior {
case .always:
if #available(iOS 11.0, *) {