Kofktu / KUIPopOver

Easy to use PopOver in iOS
MIT License
583 stars 37 forks source link

blur background VC or otherwise help popOver be more apparent? #19

Open wdcurry opened 5 years ago

wdcurry commented 5 years ago

As per the subject line, a bit of isolation might help the popOver stand out more.

wdcurry commented 5 years ago

Currently it is easy to manage as i always use SwifterSwift and adjust the FadeOut view method to animate alpha to 0.5 on presentation and FadeIn on dismissal.

cozzin commented 5 years ago

@wdcurry Hi, I think you want to change the alpha of view under popOver. I hope this can help you.

class CustomPopOverViewController: UIViewController, KUIPopOverUsable {    
    override func viewWillAppear(_ animated: Bool) {
        super.viewWillAppear(animated)
        presentingViewController?.view.alpha = 0.5
    }

    override func viewWillDisappear(_ animated: Bool) {
        super.viewWillDisappear(animated)
        presentingViewController?.view.alpha = 1
    }
}
Kofktu commented 5 years ago

@cozzin I'll check it out and support it.