-
Notifications
You must be signed in to change notification settings - Fork 1.9k
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
Date cells and month/year get messed up when changing orientation from portrait to landscape and vice versa #1022
Comments
Can you check if it is working with my change? #766 |
Same problem here. |
@mxp7064 i faced this issue you just set aspect to fit content mode for CalenderView. |
this still seems to be happening even with change 766, @VDPurohit can you post your code you used to fix it ? not sure what view to set for content mode. Thanks! @asam139 it seems to only be an issue with iphone x (xs) screens, i tried on an emulator on an iphone 6s and it worked fine, maybe it has something to do with safe areas? |
Just started using this calendar today, and had the same thing happen. Year jumped to 2035 in May. Rotated the iPad and it jumped back. |
@ajprala set content mode of calendar view:-select calendar view->Inside Attribute inspector -> content mode set to scale to fill. |
Anyone news on this? I'm getting the same thing with the 2035 date as well. I've tried both content mode suggestions. |
having the same issue |
pull request
|
Date cells and month/year get messed up when changing orientation from portrait to landscape and vice versa. The cells misalign and month/year goes to random like year 2035 or 2006. After that when I change orientation again everything goes back to normal, very strange bug!
Integration method: cocoapods
Steps to reproduce:
Change orinetation from landscape to portrait and vice versa
ipad mini 2 and iphone 6 both ios 12.1
Xcode version. 10.1
FSCalendar version: multiple versions have this issue, I tried 2.6, 2.7.9 and 2.8.0
Screenshots:
I start with for example 11/11/2018 date selected (current day by default) and I change orientation and get this:
I managed to make a temporary workaround which seems to work only for version 2.7.9:
override func viewWillTransition(to size: CGSize, with coordinator: UIViewControllerTransitionCoordinator) { super.viewWillTransition(to: size, with: coordinator) coordinator.animate(alongsideTransition: {_ in self.calendar.reloadData() }, completion: nil) }
It looks almost the same as this unsolved issue:
#434
The text was updated successfully, but these errors were encountered: