Githawk: Orientation change hides/removes Tabbar

Created on 27 Nov 2018  ·  25Comments  ·  Source: GitHawkApp/GitHawk

Steps to reproduce:

  • Have phone in portrait mode
  • Go to settings ~> view source code (Notice the Tabbar)
  • Rotate to landscape
  • Rotate to portrait
  • Tabbar is gone

Edit: The device used must have split view landscape


Bug Report Dump (Auto-generated)

Version 1.25.0 (1542806489)
Device: iPhone XR (iOS 12.1)
TestFlight: false

🐛 bug ❓ help wanted

All 25 comments

Can’t repro on the 8.

Can anyone else reproduce?

Sent with GitHawk

Can't repro on XS (12.1.1)

Nope: X 12.1

Sent with GitHawk

This XR specific? I gotta take a video and upload

Sent with GitHawk

I’m gonna look into it more. See where the Tabbar is disappearing to.

Clarification: I’m speaking of the bottom Tabbar (inbox, search, bookmarks, settings)

Sent with GitHawk

Oh wait a minute 😅. All those phone mentioned above don’t have the split view landscape right?

Sent with GitHawk

Nah, so maybe XS Max as well?

I mean ya I think this only affects phones/iPads who have split view when in landscape

iPhone 8,X,Xs don’t. Makes sense why you couldn’t reproduce

If XS Max has splitview that would be a good device to test if you can reproduce

Sent with GitHawk

XS Max supports it aye (bigger than XR) haven't got one though 😢 Sims should be able to help ya tho!

Ya I shall check soon. In class now 😁

Sent with GitHawk

Ahh timezones you crazy crazy thing 😄

Update:
Tested on iPad Pro (3rd gen)
Tested on iPhone XS Max

  • Doesn’t happen on iPad since iPads are always in split view

  • Happens on iPhone XS Max. I assume this bug applies to all devices who switch between regular and split view.

Sent with GitHawk

@Huddie wanna do some debugging on this since you've got the big phone? I _think_ this is the source of the bug:

https://github.com/GitHawkApp/GitHawk/blob/907ee5e475e67f7584c91aa0b8c2f8ab7a22b72b/Classes/View%20Controllers/SplitViewControllerDelegate.swift#L35

Sure. I’ll give it a looking

Sent with GitHawk

@rnystrom what’s the purpose that line serves?
I took it out and stuff seems to work. Just curious what it’s doing

Sent with GitHawk

I think it’s for VCs that need to hide when pushed (like Issues). Does that still work fine without this line when changing rotation?

Sent with GitHawk

@rnystrom pretty sure. I’ll check again

Sent with GitHawk

Seems to work. Any specific device / steps I should try just to make sure?

Sent with GitHawk

Just a quick note:

IssueViewController has in the init

self.hidesBottomBarWhenPushed = true

And newIssueViewController has

viewController.hidesBottomBarWhenPushed = true

So there are individual vcs taking care of this on their own.

Sent with GitHawk

Also I ran the unit tests for split view (Awesome that we have these btw) and one failed on 2 asserts. I’m not sure if it failed because of a technical reason or because there would actually be an issue. Seems to be checking if each vc on the stack has hidesBottomBarWhenPushed enabled (the last 2 fail).

I’d have to look over and understand the test + splitViewControllerDelegate better to see if there’s an issue. Running the app on the simulator it seems to function normal so I’m not sure. If someone more familiar with these section has some input I’m all ears.

Sent with GitHawk

Can you look up the blame on the test to see where it came from? Sorry I totally forgot why this exists lol.

Sent with GitHawk

https://github.com/GitHawkApp/GitHawk/commit/d6219f05e

Which fixes #296

I span up the iPhone 7 Plus sim and tried to reproduce. To be honest I'm not fully sure I understand the steps but I did not see an issue.

I tried:

  • Switching to split view

    • Opening an issue

  • Switching to portrait
  • Worked well

And:

  • Opening an issue in portrait
  • Switching to split view
  • Switching back to portrait
  • Worked well

If I am misunderstanding the issue let me know what steps to try and I'll give it a go, otherwise it seems like the issue has sorted itself out either through iOS updates (iOS 10 was when this issue was brought up) or app updates (The app has been updated a bunch since then).

Also #296 was fixed by https://github.com/GitHawkApp/GitHawk/commit/d6219f05e on Sep 10 2017, where as #370 was fixed by https://github.com/GitHawkApp/GitHawk/commit/9cb36a13e on Sep 26 2017

I think its possible https://github.com/GitHawkApp/GitHawk/commit/9cb36a13e could have solved the issue and https://github.com/GitHawkApp/GitHawk/commit/d6219f05e may have been unnecessary and just left in there but again I'm not sure

I think as long as the tab bar goes away on Issues and stays gone through orientation changes on Plus devices, were golden. Happy to merge a PR on this!

And thanks for all the detective work @Huddie!

Sent with GitHawk

Sounds good. I’m going to test it out again to make sure I covered all devices and sequences and then update unit tests and push 👌

Sent with GitHawk

Was this page helpful?
0 / 5 - 0 ratings

Related issues

BasThomas picture BasThomas  ·  3Comments

weyert picture weyert  ·  3Comments

rnystrom picture rnystrom  ·  3Comments

weyert picture weyert  ·  3Comments

Iron-Ham picture Iron-Ham  ·  3Comments