Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Disable monitorOrientation in sencha touch

How to disable monitorOrientation property in sencha touch globally?

Please help.

like image 628
thecodeparadox Avatar asked Jun 11 '11 04:06

thecodeparadox


2 Answers

If by disable you mean prevent the orientation from changing then it cannot be done in a clean way (at least on the iPhone platform).

You could (possibly) investigate the idea of re-oritentating the display when the orientation changes as described here, although I'm pretty sure iOS won't let you prevent it (you may have some luck with Android)

This thread poses a similar question.

like image 155
JamesHalsall Avatar answered Sep 27 '22 19:09

JamesHalsall


You can disable, block the orientation in portrait/ landscape or other using :

  • For Android if you open with Eclipse: The AndroidManifest under your "Application Nodes" => Screen Orientation

  • For all system (IOS, Android, BlackBerry, WebOS ... ) : You can do this using Phonegap : it let you encapsule your app in a WebView using HTML5. You just have to create a config.xml like this : https://build.phonegap.com/docs/config-xml and add this : in the balise.

Next, you just have to compile your app using http://build.phonegap.com . It's free, easy and fast to use.

Hope this help you ;)

like image 26
Erowlin Avatar answered Sep 27 '22 21:09

Erowlin