Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

iPhone App on iPad not responding to touch at first start

If my iPhone App (not universal) starts in landscape mode on my iPad (3rd gen) it does not respond to any touch until I either press the 1x/2x Button or change the orientation. After that it works as normal. If I start it on my iPhone 5 in landscape mode, it works like a charm.

shouldAutorotateToInterfaceOrientation gives a YES in every View, so I think that's not the problem here.

The first View is a tabbar-view.

like image 829
CPlusPlus Avatar asked Nov 03 '22 10:11

CPlusPlus


2 Answers

I have the same problem too on my iPad mini with iOS6.0.1.

What I do to solve the problem is to set the Supported interface orientations to all off in the info.plist.

Next, add the Supported interface orientations (iPad) in info.plist and only add the Potrait (bottom home button) in it.

It should make no difference to the apps orientation provided that you set it properly in the view controller. Also, make sure you set a correct initial interface orientation.

It then solves my problem.

like image 79
Tony Tse Avatar answered Nov 15 '22 00:11

Tony Tse


The above answers are a bit difficult, especially when using Xamarin. This answer does work:

from another question: iphone app doesn't respond after starting in landscape orientation on iPad

The comment of Daniel Sandland did solve it for me:

[[UIApplication sharedApplication] setStatusBarHidden:NO withAnimation:UIStatusBarAnimationNone];

in didFinishLaunchingWithOptions,

(the C# variant for Xamarin)

like image 28
Hugo Logmans Avatar answered Nov 14 '22 23:11

Hugo Logmans