Devices with screen density 440 dpi are not compatible with app being published on Google Play

你。 提交于 2020-02-22 04:52:05

问题


After adding <compatible-screens> block to AndroidManifest.xml some devices become incompatible. For example Pixel 3 and Pixel 3a. Both have a density screen 440 DPI. However all other devices from Google are compatible. The thing is I need to support limited set of devices (the UI is not suitable for tablets or devices with low resolutions).

My idea was these devices might belong to

<screen android:screenSize="normal" android:screenDensity="420" />
<screen android:screenSize="normal" android:screenDensity="480" />

or

<screen android:screenSize="large" android:screenDensity="420" />
<screen android:screenSize="large" android:screenDensity="480" />

buckets.

Setting android:screenDensity="440" is not working. Google Play prohibits uploading apk with such screen density.

Here is a mentioned above complete block of code

<compatible-screens>
    <screen android:screenSize="normal" android:screenDensity="xhdpi" />
    <screen android:screenSize="normal" android:screenDensity="xxhdpi" />
    <screen android:screenSize="normal" android:screenDensity="xxxhdpi" />
    <screen android:screenSize="normal" android:screenDensity="420" />
    <screen android:screenSize="normal" android:screenDensity="480" />
    <screen android:screenSize="normal" android:screenDensity="560" />
    <screen android:screenSize="normal" android:screenDensity="640" />

    <screen android:screenSize="large" android:screenDensity="xhdpi" />
    <screen android:screenSize="large" android:screenDensity="xxhdpi" />
    <screen android:screenSize="large" android:screenDensity="xxxhdpi" />
    <screen android:screenSize="large" android:screenDensity="420" />
    <screen android:screenSize="large" android:screenDensity="480" />
    <screen android:screenSize="large" android:screenDensity="560" />
    <screen android:screenSize="large" android:screenDensity="640" />
</compatible-screens>

I was trying to upload apk files with different combinations of screenSize and screenDensity and check if those devices become compatible. I have not found it yet.


回答1:


Add below code in AndroidManifest.xml above application tag

<supports-screens
    android:anyDensity="true"
    android:largeScreens="true"
    android:normalScreens="true"
    android:resizeable="true"
    android:smallScreens="true"
    android:xlargeScreens="true" />



回答2:


There is no value 440 available, while you could still define a minimum screen width in DPI with android:requiresSmallestWidthDp, with a value larger than the screens to filter out.

https://developer.android.com/guide/topics/manifest/supports-screens-element.html



来源:https://stackoverflow.com/questions/57852700/devices-with-screen-density-440-dpi-are-not-compatible-with-app-being-published

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!