How to prevent an app from switching the layout to landscape.

by Edo Noordhuizen » Thu, 09 Jul 2009 00:36:26 GMT


Sponsored Links
 Hi,

I can't seem to find a way to prevent my application from switching to
landscape orientation when I tilt my G1.
I need to prevent my app from switching to landscape mode so my game
does not become unplayable! :-(

Can anybody tell me how to prevent this??

Thanks,
Edo

--~--~---------~--~----~------------~-------~--~----~



How to prevent an app from switching the layout to landscape.

by Mark Murphy » Thu, 09 Jul 2009 00:39:22 GMT


 


android:screenOrientation="portrait" in your manifest will do it:

 http://developer.android.com/guide/topics/manifest/activity-element.html 

-- 
Mark Murphy (a Commons Guy)
 http://commonsware.com  |  http://twitter.com/commonsguy 

Warescription: Three Android Books, Plus Updates, $35/Year

--~--~---------~--~----~------------~-------~--~----~


Sponsored Links


How to prevent an app from switching the layout to landscape.

by Alslayer » Fri, 10 Jul 2009 03:47:46 GMT


 I just found the android:screenOrientation="portrait" and it works
great.

--~--~---------~--~----~------------~-------~--~----~



Other Threads

1. How to make a multi-player game on Android

Wonder how can we make a multi-player game in android. Lets say for 2
players like Chess, Scrabble, Draughts, etc.
Can anyone guide me on this please? Thank you.

-- 

2. Fw: WTA : delete email yg sudah dipush ke N1

Walah gk da cara lain ntil?cara resetnya gmn ya?

------Original Message------
From: riswan
To: Romy
To: id-android@googlegroups.com
Subject: Re: [id-android] WTA : delete email yg sudah dipush ke N1
Sent: Mar 5, 2010 5:04 PM

Wah harus reset tuh sob wkwkwkk

Kejebak dah....

Reg pertama pake email yg buat Gtalk aja pastinya...
@jakontil
ris...@naekgenteng.com

-----Original Message-----
From: "Romy" <romy.i...@gmail.com>
Date: Fri, 5 Mar 2010 10:02:15 
To: <id-android@googlegroups.com>
Subject: [id-android] WTA : delete email yg sudah dipush ke N1

As subject caranya gmn ya?td sblmnya gk tau kalau msk market dia minta email 
gmail,alhasil skrg email yg trafficnya tinggi yg dipush ke N1. Udh tau battry 
N1 boros bgt pk push email yg trafficnya tinggi lg hehehe

Thx

by God Of Odin

-- 
"Indonesian Android Community [id-android]" 

3. ANR with annotation

4. Trying to compile Android under cygwin

5. Is it possible to set minimum heap size for each application.?

6. Ada yang cara wifi tethering dari LAPTOP ke Android

7. Paket Data Internet Apa Kira-Kira yang Cocok Buat Android? IM3, XL ato Simpati?