简体   繁体   English

屏幕方向为纵向和反向纵向

[英]Screen orientation to portrait and reverse portrait

My app target 2.2 and later and want to support orientation only on portrait and reverse portrait. 我的应用定位到2.2及更高版本,并且希望仅支持纵向和反向方向。 and the problem is i can't declare 问题是我无法声明

android:screenOrientation="reversePortrait" 机器人:screenOrientation = “reversePortrait”

in manifest as it is only available from api level 9. How is it possible to do this by supporting android 2.2 and later. 在清单中,因为它仅适用于api 9级。如何通过支持android 2.2及更高版本来做到这一点。

According to this post, 根据这篇文章,

How to detect exact orientation of device in Froyo? 如何在Froyo中检测设备的确切方向?

it is not possible to use portrait mode with reversed API 8. 反向API不能使用纵向模式。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM