swiftuivisualeffectviewxcode6.4

Why my Modally Presented UIVisualEffect View is done in dark grey?


I am trying to to use UIVisualEffectView on my modally presented view which gonna be sign in view for user.I really dont know what is going on with UIVisualEffectView.When the modal animation appear,it work fine.But,when the animation was done,the effect turn to dark grey,Any help with that?I am stucking with that for too long.

My Simulator,Also happen on iPhone

My Storyboard

Please Help?

Here is my source code , Download


Solution

  • Underlying views will disappear once a modal covers them. To prevent this from happening, you need to set the UIModalPresentationStyle of the modal view controller to OverCurrentContext:

    ModalVC.modalPresentationStyle = UIModalPresentationStyle.OverCurrentContext