Android Market隐藏我的应用程序到某些平板电脑(如Nexus 7)

时间:2012-12-10 21:07:05

标签: android permissions android-manifest google-play uses-feature

这是我对Manifest.xml的配置,我不明白为什么Nexus 7和其他平板电脑无法从市场上下载这个应用程序。

<uses-sdk android:minSdkVersion="10" android:targetSdkVersion="10"/>

<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.ACCESS_WIFI_STATE" />
<uses-permission android:name="android.permission.GET_ACCOUNTS" />
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" android:required="false"/>
<uses-permission android:name="android.permission.READ_PHONE_STATE" android:required="false"/>
<uses-permission android:name="android.permission.CAMERA" android:required="false"/>
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" android:required="false" />
<uses-permission android:name="android.permission.CALL_PHONE" android:required="false" /> 
<uses-feature android:name="android.hardware.camera" android:required="false"/> 
<uses-feature android:name="android.hardware.camera.autofocus" android:required="false"/>

在Developer Console中有一个字符串Layout schermo:SMALL NORMAL LARGE XLARGE,所以我认为问题是权限。有什么建议吗?

所有清单

<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="**********"
android:versionCode="3"
android:versionName="1.4" >

<uses-sdk 
    android:minSdkVersion="10" 
    android:targetSdkVersion="10"/>

<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.ACCESS_WIFI_STATE" />
<uses-permission android:name="android.permission.GET_ACCOUNTS" />
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" android:required="false"/>
<uses-permission android:name="android.permission.READ_PHONE_STATE" android:required="false"/>
<uses-permission android:name="android.permission.CAMERA" android:required="false"/>
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" android:required="false" />
<uses-permission android:name="android.permission.CALL_PHONE" android:required="false" /> 
<uses-feature android:name="android.hardware.camera" android:required="false"/> 
<uses-feature android:name="android.hardware.camera.autofocus" android:required="false"/>




<application
    android:icon="@drawable/ic_launcher"
    android:label="@string/app_name" >
    <activity
        android:name=".SplashScreenActivity"
        android:label="@string/app_name"
        android:screenOrientation="portrait"
        android:theme="@style/Theme.Transparent" >
        <intent-filter>
            <action android:name="android.intent.action.MAIN" />
            <category android:name="android.intent.category.LAUNCHER" />
        </intent-filter>
    </activity>
    <activity
        android:name="**************"
        android:screenOrientation="portrait"
        android:theme="@style/Theme.Transparent" >
    </activity>
    <activity
        android:name="InfoServizio"
        android:screenOrientation="portrait"
        android:theme="@style/Theme.Transparent" >
    </activity>
    <activity
        android:name="NewProfilo"
        android:screenOrientation="portrait"
        android:theme="@style/Theme.Transparent" >
    </activity>
    <activity
        android:name="MiaDietaActivity"
        android:screenOrientation="portrait"
        android:theme="@style/Theme.Transparent" >
    </activity>
    <activity
        android:name="Percentuali"
        android:screenOrientation="portrait"
        android:theme="@style/Theme.Transparent" >
    </activity>
    <activity
        android:name="DatiFisiciUtente"
        android:screenOrientation="portrait"
        android:theme="@style/Theme.Transparent" >
    </activity>
    <activity
        android:name="ListViewFoodCategoryActivity"
        android:screenOrientation="portrait"
        android:theme="@style/Theme.Transparent" >
    </activity>
    <activity
        android:name="ListViewFoodActivity"
        android:screenOrientation="portrait"
        android:theme="@style/Theme.Transparent" >
    </activity>
    <activity
        android:name="FoodDescriptionActivity"
        android:screenOrientation="portrait"
        android:theme="@style/Theme.Transparent" >
    </activity>
    <activity android:name="MiaDietaActivityWebView" >
    </activity>
    <activity
        android:name="AggiungiNuovoPiattoActivity"
        android:screenOrientation="portrait"
        android:theme="@style/Theme.Transparent" >
    </activity>
    <activity
        android:name="EmailActivity"
        android:screenOrientation="portrait"
        android:theme="@style/Theme.Transparent" >
    </activity>
    <activity
        android:name="ProfiloActivity"
        android:screenOrientation="portrait"
        android:theme="@style/Theme.Transparent" >
    </activity>
    <activity
        android:name="InsertInitialDataActivity"
        android:screenOrientation="portrait"
        android:theme="@style/Theme.Transparent" >
    </activity>
    <activity
        android:name="LoginActivity"
        android:screenOrientation="portrait"
        android:theme="@style/Theme.Transparent" >
    </activity>
    <activity
        android:name=".StoricoTabActivity"
        android:screenOrientation="portrait"
        android:theme="@style/Theme.Transparent" >
    </activity>
    <activity
        android:name="PesoRiepilogoActivity"
        android:screenOrientation="portrait"
        android:theme="@style/Theme.Transparent" >
    </activity>
    <activity
        android:name="GraficoRiepilogoActivity"
        android:screenOrientation="landscape"
        android:theme="@style/Theme.Transparent" >
    </activity>
    <activity
        android:name="StoricoPesoActivity"
        android:screenOrientation="portrait"
        android:theme="@style/Theme.Transparent" >
    </activity>
    <activity
        android:name="StoricoPietanzeActivity"
        android:screenOrientation="portrait"
        android:theme="@style/Theme.Transparent" >
    </activity>
    <activity
        android:name="AggiungiNuovoPiattoSecondoPassaggioActvity"
        android:screenOrientation="portrait"
        android:theme="@style/Theme.Transparent" >
    </activity>
    <activity
        android:name="ActivityScattaFoto"
        android:screenOrientation="portrait" >
    </activity>
    <activity
        android:name="ListViewMyFoodActivity"
        android:screenOrientation="portrait"
        android:theme="@style/Theme.Transparent" >
    </activity>
    <activity
        android:name="ListViewMyFoodCategoryActivity"
        android:screenOrientation="portrait"
        android:theme="@style/Theme.Transparent" >
    </activity>
    <activity
        android:name="SearchActivity"
        android:screenOrientation="portrait"
        android:theme="@style/Theme.Transparent" >
    </activity>
    <activity
        android:name="HomeActivity"
        android:screenOrientation="portrait"
        android:theme="@style/Theme.Transparent" >
    </activity>
    <activity
        android:name="GraficoOK"
        android:screenOrientation="portrait"
        android:theme="@style/Theme.Transparent" >
    </activity>
    <activity
        android:name="FormuleActivity"
        android:screenOrientation="portrait"
        android:theme="@style/Theme.Transparent" >
    </activity>
    <activity
        android:name="CreditsActivity"
        android:screenOrientation="portrait"
        android:theme="@style/Theme.Transparent" >
    </activity>
    <activity
        android:name="AssociaDietologoActivity"
        android:screenOrientation="portrait"
        android:theme="@style/Theme.Transparent" >
    </activity>
    <activity android:name="org.achartengine.chartdemo.demo.chart.XYChartBuilder" />
    <activity android:name="org.achartengine.chartdemo.demo.chart.PieChartBuilder" />
    <activity android:name="org.achartengine.GraphicalActivity" />
    <activity android:name=".GeneratedChartDemo" />
    <activity
        android:name="AttesaDietologoActivity"
        android:screenOrientation="portrait"
        android:theme="@style/Theme.Transparent" >
    </activity>
    <activity
        android:name="FacebookLikeActivity"
        android:screenOrientation="portrait" >
    </activity>
    <activity
        android:name="TwitterGoActivity"
        android:screenOrientation="portrait" >
    </activity>
    <activity
        android:name="CalendarView"
        android:screenOrientation="portrait"
        android:theme="@style/Theme.Transparent" >
    </activity>
</application>

</manifest>

2 个答案:

答案 0 :(得分:5)

您不能将android:required="false"与权限一起使用;它仅适用于uses-feature。某些权限意味着功能。在这种情况下,android.permission.CALL_PHONE隐含android.hardware.telephony。 Nexus 7没有此功能,将被过滤掉。试试这个:

<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.ACCESS_WIFI_STATE" />
<uses-permission android:name="android.permission.GET_ACCOUNTS" />
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
<uses-permission android:name="android.permission.READ_PHONE_STATE" />
<uses-permission android:name="android.permission.CAMERA" />
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
<uses-permission android:name="android.permission.CALL_PHONE" />

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

答案 1 :(得分:1)

Nexus 7没有自动对焦功能。因此,如果它显示在您的<uses>标记中,则该应用将对所有没有该功能的设备隐藏。如果您的应用不需要自动对焦,只需要相机,那么请删除<uses>标签,您应该可以继续使用所有带相机的设备。您可能还想将摄像机的<uses>标签更改为camera.any,否则会因为缺少背面摄像头而失败。