Android Setting screen orientation

Source: Internet
Author: User

Setup method: Add an attribute android:screenorientation to the activity in Androidmanifest.xml. For example, set the activity to landscape

<activity android:name= ". Login "
android:screenorientation= "Landscape" >
</activity>

The screenorientation values are as follows:
Landscape: Landscape
Portrait: Portrait
unspecified: Default value, automatically switched by system-determined state
User : The orientation value currently set by users.
behind: The orientation value of the activity to be displayed next.
Sensor : direction of transducer
nosensor: do not use the sensor, this effect is almost equal to unspecified

Android Setting screen orientation

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.