From 1b6a38609ef0691195586d54845210804fdc4135 Mon Sep 17 00:00:00 2001 From: pauluhn Date: Thu, 17 Aug 2017 18:09:58 -0500 Subject: [PATCH] Fix UI bug. --- Segmentio/Source/Segmentio.swift | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Segmentio/Source/Segmentio.swift b/Segmentio/Source/Segmentio.swift index da082a7..ad7f709 100644 --- a/Segmentio/Source/Segmentio.swift +++ b/Segmentio/Source/Segmentio.swift @@ -253,7 +253,7 @@ open class Segmentio: UIView { bottomSeparatorView = UIView(frame: CGRect.zero) setupConstraintsForSeparatorView( separatorView: bottomSeparatorView, - originY: frame.maxY - height + originY: bounds.maxY - height ) } } @@ -271,7 +271,7 @@ open class Segmentio: UIView { item: separatorView, attribute: .top, relatedBy: .equal, - toItem: superview, + toItem: self, attribute: .top, multiplier: 1, constant: originY