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

After dismissing the view overlaps with status bar. #94

Closed
JARMourato opened this issue Jan 19, 2016 · 0 comments
Closed

After dismissing the view overlaps with status bar. #94

JARMourato opened this issue Jan 19, 2016 · 0 comments

Comments

@JARMourato
Copy link
Contributor

After reading all the issues I concluded that my issue is related to the issues #71 #77 #78 . I'm using autolayout so it might be connected to that. I've found a solution, which is to move the line that fixes the status bar from the viewDidDisappear to the viewWillDisappear. Also, I think a better way is to add an animation so that it all goes smoothly. Code below:

public override func viewWillAppear(animated: Bool) {
super.viewWillAppear(animated)

statusBarHidden = UIApplication.sharedApplication().statusBarHidden
UIApplication.sharedApplication().setStatusBarHidden(true, withAnimation: .Fade)

}

public override func viewWillDisappear(animated: Bool) {

    super.viewWillDisappear(animated)
    UIApplication.sharedApplication().setStatusBarHidden(statusBarHidden, withAnimation: .Fade)

}

Just a suggestion.

Cheers

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

1 participant