支持LG G3,仅限于手机



我有一个Android应用程序,只能在手机上使用。目前,我使用了谷歌文档中的示例,在该示例中,我在清单中设置了兼容的屏幕元素。最近,一位用户抱怨游戏商店说该应用程序与他们的手机不兼容,他们有LG G3。经过调查,我意识到这个问题很可能是由我的手机屏幕分辨率与我定义的屏幕不兼容引起的。我在谷歌Play商店上发现了这个后Android应用程序与LG G3不兼容(密度538,尺寸2560x1440)?其示出了必须定义的附加屏幕元素。我的问题是,有人能确认使用这个额外的屏幕元素,将screenSize设置为normal,将screenDensity设置为640会起作用吗?

<screen android:screenDensity="640" android:screenSize="normal" />

我想允许使用这款手机的用户使用该应用程序,但我希望目前该应用程序仅限于手机。

谢谢!!!

<uses-sdk
    android:minSdkVersion="10"
    android:targetSdkVersion="10" />
<!-- Only permit app to be used on handsets, prevent tablets -->
<compatible-screens>
    <!-- all small size screens -->
    <screen android:screenDensity="ldpi" android:screenSize="small" />
    <screen android:screenDensity="mdpi" android:screenSize="small" />
    <screen android:screenDensity="hdpi" android:screenSize="small" />
    <screen android:screenDensity="xhdpi" android:screenSize="small" />
    <screen android:screenDensity="480" android:screenSize="small" />
    <!-- all normal size screens -->
    <screen android:screenDensity="ldpi" android:screenSize="normal" />
    <screen android:screenDensity="mdpi" android:screenSize="normal" />
    <screen android:screenDensity="hdpi" android:screenSize="normal" />
    <screen android:screenDensity="xhdpi" android:screenSize="normal" />
    <!-- Nexus 5 : 445ppi -->
    <screen android:screenDensity="480" android:screenSize="normal" />
    <!-- LG G3 QHD Resolution -->
    <screen android:screenDensity="640" android:screenSize="small" />
    <screen android:screenDensity="640" android:screenSize="normal" />
</compatible-screens>

据我记忆所及,我可以在我的PlayStore发布帐户中分别为每个设备允许我的应用程序。这会更准确,但不容易维护。

另一种方法:尝试找到一个共享你想要锁定的设备的功能。相应地设置一个<uses feature>-Tag。我会立刻想到"电话"这个功能。所有功能和用法:http://developer.android.com/guide/topics/manifest/uses-feature-element.html

有关所有筛选器的常规信息:http://developer.android.com/google/play/filters.html

最新更新