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

Modal presentation -> Rotate -> Dismiss #64

Closed
chrischute opened this issue Jun 5, 2019 · 3 comments
Closed

Modal presentation -> Rotate -> Dismiss #64

chrischute opened this issue Jun 5, 2019 · 3 comments

Comments

@chrischute
Copy link

chrischute commented Jun 5, 2019

First off, great project! Simple and easy to use.

I had a layout issue caused by the following steps:

  1. Modal presentation over the content view controller
  2. Rotate the device
  3. Dismiss the modally presented view
  4. Now the content view is not sized properly

I traced these steps to viewWillTransition and specifically the following line: self.contentContainerView.frame = self.contentFrame(visibility: self.isMenuRevealed). For me, view.frame is not correct and instead should use the size argument to viewWillTransition in SideMenuController.swift. I changed the line to the following: self.contentContainerView.frame = CGRect(origin: .zero, size: size). This is probably a hack, but thought I'd bring it up in case you see the proper fix.

Best,
Chris

@kukushi
Copy link
Owner

kukushi commented Jun 8, 2019

Thanks for the detail description and hint.
You can try the fix on the develop branch.

@gsoykan
Copy link

gsoykan commented Jul 9, 2019

Simulator Screen Shot - iPhone 8 - 2019-07-09 at 11 31 53

I got this layout during the following situation:

  • First a viewController is pushed to the navigation and that rotates the screen horizontally
  • Then when that viewController is popped up the rotation is going back to vertical (portrait)
  • And then you can see the black portion in the screen shot which is part of SideMenuController because it has clear color.

I Could not manage to solve the problem. Hope you can emulate the problem and fix.
Because of this I will not be able to use this project.
Nevertheless I really liked it.
Best.

@psnt143
Copy link

psnt143 commented Dec 24, 2019

how to show sidemenu open when Rotate the device?

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

4 participants