Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Popover height keeps growing every time I open and close the popover #122

Open
SimonFernandes7 opened this issue Jan 23, 2019 · 5 comments

Comments

@SimonFernandes7
Copy link

simulator screen shot - iphone 7 plus - 2019-01-23 at 16 48 42
simulator screen shot - iphone 7 plus - 2019-01-23 at 16 48 35

let options = [ .type(.up), .animationIn(0.3) ] as [PopoverOption] let popover = Popover(options: options, showHandler: nil, dismissHandler: nil) popover.show(passwordValidationView, fromView: sender as! UIButton)

As you can see this custom view size keeps on increasing as it is open multiple times

@hslightnin
Copy link

did you figure this one out? I just noticed the same thing today

@nizzam
Copy link

nizzam commented Mar 14, 2019

What's the solution ?

@HelloiWorld
Copy link

Me too,to figure this, I set the arrowSize zero , but it looks so strange.

@Cu-Toof
Copy link

Cu-Toof commented Jun 20, 2019

switch self.popoverType {
        case .up, .down, .auto:
            frame.size.height += self.arrowSize.height
        case .left, .right:
            frame.size.width += self.arrowSize.height
        }

I find a above code in func create(). This is increase width/height of view.

@Cu-Toof
Copy link

Cu-Toof commented Jun 20, 2019

My solution: Just remove a below code in Popover file:

override open func layoutSubviews() {
        super.layoutSubviews()
        self.contentView.frame = self.bounds
    }

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants