ergunemr / BottomPopup

BottomPopup provides a popup-like presentation style to any view controller
MIT License
875 stars 88 forks source link

Unable to present bottomPopup above all views #18

Open JhonnyTawk opened 4 years ago

JhonnyTawk commented 4 years ago

I have a view (Now playing music) above Tabbar I am adding it like this appDelegate.window?.rootViewController?.addChild(nowPlayingView) appDelegate.window?.addSubview(miniPlayerView.view) when I click on it. It shows the full view inside the full view there is a button that displays the BottomPopup I am unable to display the BottomPopup above the presented View I tried the different solution but only 1 worked with me

`

let transition = CATransition()

transition.type = CATransitionType.push

transition.subtype = CATransitionSubtype.fromTop

    popupVC.view.layer.add(transition, forKey: nil)

    appDelegate.window?.rootViewController?.addChild(popupVC)

    appDelegate.window?.addSubview(popupVC.view)

    popupVC.didMove()

` and that's lead to another issue that's I am unable to dismiss it on swipe please, can someone help? Thank you