Created attachment 8793330 [details] IMG_0050.PNG Build: 5.3(1) RC Device: iPad Air 2 iOS: 10.0.1 Steps to reproduce: 1. Launch Firefox in portrait view 2. Open the menu 3. Background Firefox by pressing the home button 4. Restore Firefox Actual results; - The menu layout will be broken and all the icons will overlap Expected: - The menu should be correctly displayed Note: - This issue was encountered on iPad Air 2 and iPad mini 4 running iOS 10. - This issue was not reproduced on 5.2(1) released version.
This is a major UI regression affecting all iPads with iOS 10 and it should be fixed in the 5.3 release - if it's not too late
Not reproducible on my iPhone 6 (iOS 10). Seems tablet specific.
Assignee: nobody → fpatel
Priority: -- → P1
I looked into this a bit more today. This issue can be fixed by closing the menu and reopening it. Sadly, I'm having trouble understanding why exactly this is happening. I'm writing my thoughts here for when I want to get back to this. A change in the menuViewController's appState when going into the background triggers a layout. That triggers a full reloadData of the Menu which causes "prepareLayout" in the Menu's colletionViewLayout. Turns out the bounds of the collectionView are incorrect (width=0). But the layout continues anyways and fails horribly (see screenshot). This happens because the constraints for the width aren't set the same way they are for the height. One way of fixing this. Is to fix the width of the popOver. This way the case of the collectionview ever being 0 never happens. This all wouldn't be such a big deal if once the app appeared again viewDidAppear was triggered and layout happened again. But it isn't
Thanks for looking into this. This seems related to the iOS 10 bug that was fixed a few weeks back where the menu wasn't correctly laying out at all on iPads . From what I can recall, on iOS 10, the UI > Turns out the bounds of the collectionView are incorrect (width=0). But the layout continues anyways and fails horribly (see screenshot). My gut says that the timing of the reloadData which in turn forces the relayout is occurring at an incorrect time in the view lifecycle. For example, if you try laying things out manually without autolayout prior to viewDidLayoutSubviews, you get some undefined frame values.  https://github.com/mozilla-mobile/firefox-ios/pull/2070
Created attachment 8798004 [details] [review] Pull Request
Attachment #8798004 - Flags: review?(sleroux)
Comment on attachment 8798004 [details] [review] Pull Request Looks good!
Attachment #8798004 - Flags: review?(sleroux) → review+
Status: NEW → RESOLVED
Last Resolved: 2 years ago
Resolution: --- → FIXED
Verifying as fixed on master acc25e6d9. The Menu is dismissed when foregrounding Firefox.
Status: RESOLVED → VERIFIED
status-fxios-v6.0: affected → verified
You need to log in before you can comment on or make changes to this bug.