nickoneill / PermissionScope

Intelligent iOS permissions UI and unified API
MIT License
4.85k stars 507 forks source link

iPad Split View Bug #163

Closed winkelsdorf closed 8 years ago

winkelsdorf commented 8 years ago

Hi Nick,

just stumbled upon this nifty bug with the Demo playing with iPad Split View:

screenshot 2016-04-04 12 03 35 screenshot 2016-04-04 12 03 51

Notice that the 1st screenshot is actually a Split View, not Overlay. It should be centered like the underlying View.

Source from :head as of today.

Looks like should be fixable with adjusting viewWillLaoutSubviews() usage of UIScreen.mainScreen().bounds.size.

Usually I would do this implementing traitCollectionDidChange: but the views are created by code.

Edit: Not that easy to fix. We could use UIScreen.mainScreen().applicationFrame instead, but it 1) is deprecated with iOS9 2) leaves a gap at the bottom (height of the statusbar is not part of applicationFrame) 3) and has issues with the close button.

Cheers, Frederik

nickoneill commented 8 years ago

Thanks for this! We're going to swap this to a proper modal presentation at some point in time (#148) and it might be entirely resolved by that. If not, we'll tackle afterwards.

winkelsdorf commented 8 years ago

You're welcome! Ah yes, forgot about that.. Reference to this is kept in #148, closing this for now.