Android活动不会填充WVGA屏幕

Mat*_*atx 4 layout android screen

我正在使用带按钮的简单LinearLayout开发一个Activity.当我在我的硬件(WVGA 480x800屏幕)上尝试活动时,活动仅填充标准尺寸(480x320),而操作系统本身填满整个屏幕.

可能是什么问题.

谢谢,

<?xml version="1.0" encoding="utf-8"?>
    <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
        android:orientation="vertical"
        android:layout_width="fill_parent"
        android:layout_height="fill_parent" android:background="#FFF"                    android:fitsSystemWindows="true">  
        <Button android:text="@+id/Button01" android:id="@+id/Button01"                          android:layout_width="wrap_content" 
                android:layout_height="wrap_content"></Button>
</LinearLayout>
Run Code Online (Sandbox Code Playgroud)

Mat*_*son 6

我相信您必须在清单文件中指定您希望允许应用程序扩展到更大屏幕的大小.

有关详细信息,请参阅:http://developer.android.com/guide/practices/screens_support.html#attrs.

<supports-screens>清单中有一部分属性可能包含您要查找的内容.