NimbleKit - fast iOS app development

UITabBarController in 1.9.7

Please post here if you think only NimbleKit developers can solve your problem

UITabBarController in 1.9.7

Postby npalmqvist » Wed Jun 29, 2011 10:45 pm

Since updating to 1.9.7 I got a strange message/warning in my console:
Code: Select all
2011-06-29 22:41:17.371 ST_iphone[2480:707] The view controller <UITabBarController: 0x1a5d40> returned NO from -shouldAutorotateToInterfaceOrientation: for all interface orientations. It should support at least one orientation.


It doesn't seem that something is actually "broken" compared to 1.9.6 so I'm unsure if this should be posted in the bugtracker. Any idea why it's there?
I've not specified any setting for support rotation in my code.
npalmqvist
 
Posts: 106
Joined: Thu Feb 17, 2011 10:07 pm
Location: Stockholm, SWEDEN

Re: UITabBarController in 1.9.7

Postby cactuscraig » Wed Jun 29, 2011 11:27 pm

add this to each page:
Code: Select all
function NKIsPageSupportsAutoOrientation()
{
   return "yes";
}

(and YES - make it "YES")

Then in your PLIST - see all my Supported Interface orientation options, 4 sections:
Initial interface orientation
Supported interface orientations
Supported interface orientations (iPhone)
Supported interface orientations (iPad)

Thanks to HughJohnson for the answer yesterday - viewtopic.php?f=5&t=2971
Attachments
Screen shot 2011-06-29 at 2.26.46 PM.png
Screen shot 2011-06-29 at 2.26.46 PM.png (48.2 KiB) Viewed 337 times
User avatar
cactuscraig
 
Posts: 846
Joined: Thu Feb 03, 2011 5:15 pm
Location: Scottsdale, AZ

Re: UITabBarController in 1.9.7

Postby sunny » Thu Jun 30, 2011 8:21 am

Code: Select all
function NKIsPageSupportsAutoOrientation()
{
   return "yes";
}

this is not necessary anymore, by default it is always "yes", so you need to just specify supported orientations in plist file
User avatar
sunny
Staff
 
Posts: 2666
Joined: Sat May 30, 2009 5:18 am
Location: Palo Alto, California

Re: UITabBarController in 1.9.7

Postby cactuscraig » Thu Jun 30, 2011 4:06 pm

Cool. Thanks.
User avatar
cactuscraig
 
Posts: 846
Joined: Thu Feb 03, 2011 5:15 pm
Location: Scottsdale, AZ

Re: UITabBarController in 1.9.7

Postby cactuscraig » Thu Jun 30, 2011 10:12 pm

sunny wrote:
Code: Select all
function NKIsPageSupportsAutoOrientation()
{
   return "yes";
}

this is not necessary anymore, by default it is always "yes", so you need to just specify supported orientations in plist file


I still have this error when I use NKMailComposer:
Code: Select all
The view controller <UITabBarController: 0x78371c0> returned NO from -shouldAutorotateToInterfaceOrientation: for all interface orientations. It should support at least one orientation.


I even tried adding
Code: Select all
function NKIsPageSupportsAutoOrientation()
            {
                return "yes";
            }

to the page calling the NKMailComposer - but it does not help.
User avatar
cactuscraig
 
Posts: 846
Joined: Thu Feb 03, 2011 5:15 pm
Location: Scottsdale, AZ


Return to Support

Who is online

Users browsing this forum: No registered users and 1 guest