Warning: file_get_contents(/data/phpspider/zhask/data//catemap/3/android/198.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
面向纵向的Android后端_Android_Playn - Fatal编程技术网

面向纵向的Android后端

面向纵向的Android后端,android,playn,Android,Playn,我试图改变android后端的方向,但没有改变 完全 我正在尝试将:screenOrientation=“肖像”添加到我的 manifest.xml但没有资源 有没有关于如何将我的方向改为肖像的建议?因为 默认为风景 Michael Bayne在google goups上帮助我: 您希望将以下内容添加到android/src/../YourGameActivity.java: 谢谢Michael,试着像这样在清单中设置它 android:label=“@string/app\u name”an

我试图改变android后端的方向,但没有改变 完全 我正在尝试将:screenOrientation=“肖像”添加到我的 manifest.xml但没有资源

有没有关于如何将我的方向改为肖像的建议?因为 默认为风景

Michael Bayne在google goups上帮助我:

您希望将以下内容添加到android/src/../YourGameActivity.java:


谢谢Michael,试着像这样在清单中设置它


android:label=“@string/app\u name”android:screenOrientation=“肖像”

我尝试使用清单,但对我无效。。。也许是因为playn图书馆。。。。但是在添加了ovveride函数之后,就像Michael为我说的那样,它工作得很好。您需要更改清单并覆盖
YourGameActivity.java
中的方法。
@Override public boolean usePortraitOrientation () {
    return true;
}