Discussion Forums  >  Uncategorized

Replies: 5    Views: 263

jackreeves
I hate code!
Profile
Posts: 10
Reg: Jun 29, 2011
keighley
100
09/13/11 03:24 PM (14 years ago)

lock ipad rotation

hello all, just testing my app. version 1.5 works great - both my iphone and ipad menus etc look great. only problem is i cant restrict rotation on ipad. the way my app is laid out the cornered menus are aligned to the bottom of the screen but because i can lock the rotation on the ipad they now run off the screen in landscape. any ideas? thanks in advance
 
jackreeves
I hate code!
Profile
Posts: 10
Reg: Jun 29, 2011
keighley
100
like
09/13/11 04:04 PM (14 years ago)
 
baywebnz
Aspiring developer
Profile
Posts: 92
Reg: Oct 25, 2010
location unknow...
920
like
09/13/11 06:01 PM (14 years ago)
Generally the iPad should allow rotation. However to prevent this is pretty easy: Open files BT_rotatingNavController.m and BT_rotatingTabBarController.m In each file find: if([appdelegate.rootApp.rootDevice isIPad]){ canRotate = TRUE; and replace with: if([appdelegate.rootApp.rootDevice isIPad]){ canRotate = FALSE; Clean Targets -> Build & Run Rotating the iPad should no longer change the screen orientation.
 
jackreeves
I hate code!
Profile
Posts: 10
Reg: Jun 29, 2011
keighley
100
like
09/13/11 06:48 PM (14 years ago)
great! works a treat...thanks a million
 
jackreeves
I hate code!
Profile
Posts: 10
Reg: Jun 29, 2011
keighley
100
like
09/13/11 06:52 PM (14 years ago)
one other question...but if its not possible dont worry. at the moment, now rotation is locked, both iphone and ipad applications load rss feeds of videos, when these are clicked they direct to youtube. thing is now rotation is locked these only play in portrait. anyway to at an if/else statement to allow rotation only for the pages?
 
baywebnz
Aspiring developer
Profile
Posts: 92
Reg: Oct 25, 2010
location unknow...
920
like
09/13/11 09:14 PM (14 years ago)
Not really i'm afraid - at least not easily, would take some pretty major code hacking!!!
 

Login + Screen Name Required to Post

pointerLogin to participate so you can start earning points. Once you're logged in (and have a screen name entered in your profile), you can subscribe to topics, follow users, and start learning how to make apps like the pros.