gpt4 book ai didi

android - 添加短信权限后,应用程序未显示在 Nexus 7 的 Play-Store 中

转载 作者:行者123 更新时间:2023-11-29 17:37:08 29 4
gpt4 key购买 nike

我发布的 android 应用程序显示在 Nexus 7 的 play-store 搜索结果中。
但是自从我向应用程序添加了 SMS 接收和读取权限并上传了新版本后,我无法在任何 Nexus 7(不支持 SIM 卡)但能够在 Nexus 中构建的搜索结果中看到它来自 Android-Studio 的 7 台设备。

我没有在 list 中明确设置屏幕兼容性,旧版本的应用程序在 Nexus 7 中是可以的。所以我不能假设 this SO post不适合我?

我的应用程序 list 中的权限和功能要求列表如下所示:

<uses-feature
android:glEsVersion="0x00020000"
android:required="true" />
<uses-feature android:name="android.hardware.screen.portrait" />

<uses-permission android:name="com.google.android.c2dm.permission.RECEIVE" />
<uses-permission android:name="com.google.android.providers.gsf.permission.READ_GSERVICES" />
<uses-permission android:name="android.permission.ACCESS_COARSE_LOCATION" />
<uses-permission android:name="android.permission.ACCESS_FINE_LOCATION" />
<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.GET_ACCOUNTS" />
<uses-permission android:name="android.permission.USE_CREDENTIALS" />
<uses-permission android:name="android.permission.WAKE_LOCK" />
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
<uses-permission android:name="android.permission.ACCESS_WIFI_STATE" />
<uses-permission android:name="android.permission.VIBRATE" />
<uses-permission android:name="android.permission.READ_PHONE_STATE" />
<uses-permission android:name="android.permission.CALL_PHONE" />
<uses-permission android:name="android.permission.RECEIVE_SMS" />
<uses-permission android:name="android.permission.READ_SMS" />

我没有奢侈上传任何新版本并在试错的基础上对其进行测试,但必须快速解决这个问题。

提前致谢。

最佳答案

你应该添加:

<uses-feature android:name="android.hardware.telephony" android:required="false" />

If an application requests hardware-related permissions, Google Play assumes that the application uses the underlying hardware features and therefore requires those features, even though there might be no corresponding to declarations. For such permissions, Google Play adds the underlying hardware features to the metadata that it stores for the application and sets up filters for them.

For example, if an application requests the CAMERA permission but does not declare a element for android.hardware.camera, Google Play considers that the application requires a camera and should not be shown to users whose devices do not offer a camera.

If you don't want Google Play to filter based on a specific implied feature, you can disable that behavior. To do so, declare the feature explicitly in a element and include an android:required="false" attribute. For example, to disable filtering derived from the CAMERA permission, you would declare the feature as shown below.

<uses-feature android:name="android.hardware.camera" android:required="false" />

您可以在这里找到更多信息:
http://developer.android.com/guide/topics/manifest/uses-feature-element.html

关于android - 添加短信权限后,应用程序未显示在 Nexus 7 的 Play-Store 中,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/30106268/

29 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com