Android:我的应用程序支持0个设备

前端之家收集整理的这篇文章主要介绍了Android:我的应用程序支持0个设备前端之家小编觉得挺不错的,现在分享给大家,也给大家做个参考。
你知道,我真的很失望.我花了最近5个月制作这个应用程序,从设计到编码a..z,现在我已经结束了:我的应用程序支持0个设备.

然后我花了差不多24个小时,试图弄清楚发生了什么事情,仍然无法使其工作.我需要帮助.

p.s:“本地化:默认49种语言”字段:在我的应用程序中,我只有英文的默认值/ strings.xml,但我不介意用户在其他语言的手机上会看到我的应用程序的英文.

更新:发现并添加了我澄清的答案,但接受的答案让我走正确的道路.所以谢谢

这是我得到的:

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

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

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

    <uses-feature android:name="android.hardware.CAMERA" />
    <uses-feature android:name="android.hardware.camera.AUTOFOCUS" />

    <application
        android:hardwareAccelerated="true"        
        android:allowBackup="true"
        android:icon="@drawable/ic_launcher"
        android:label="@string/app_name"
        android:theme="@style/Holo.Theme"
        android:name="org.holoeverywhere.app.Application">

        <!-- Blank Activity -->
        <activity            
            android:name=".BlankActivity"
            android:label="@string/app_name"
            android:screenOrientation="portrait"
            android:theme="@android:style/Theme.NoTitleBar">
            <intent-filter>
                <action android:name="android.intent.action.MAIN" />
                <category android:name="android.intent.category.LAUNCHER" />
            </intent-filter>
        </activity>

        <!-- Access Activity -->
        <activity                                    
            android:name=".AccessActivity"
            android:label="@string/title_activity_access"             
            android:screenOrientation="portrait">
        </activity>

        <!-- Register Activity -->
        <activity                        
            android:name=".RegisterActivity"
            android:screenOrientation="portrait"            
            android:label="@string/lbActRegister">
        </activity>

        <!-- Login Activity -->
        <activity                        
            android:name=".LoginActivity"
            android:screenOrientation="portrait"            
            android:label="@string/lbActLogin">
        </activity>

        <!-- Recovery Activity -->
        <activity            
            android:name=".RecoveryActivity"
            android:screenOrientation="portrait"
            android:label="@string/lbActRecovery">
        </activity>

        <!-- Dashboard Activity -->
        <activity                                    
            android:name=".DashboardActivity"
            android:label="@string/app_name"
            android:launchMode="singleTop"             
            android:screenOrientation="portrait"
            android:configChanges="orientation|keyboardHidden|screenSize">
        </activity>

        <!-- Edit Profile Activity -->
        <activity            
            android:name=".EditProfileActivity"
            android:screenOrientation="portrait"
            android:label="@string/lbActEditProfile">
        </activity>

        <!-- Feedback Activity -->
        <activity            
            android:name=".FeedbackActivity"
            android:screenOrientation="portrait"
            android:label="@string/lbActFeedback">
        </activity>

        <!-- TOSU Activity -->
        <activity            
            android:name=".TOSUActivity"
            android:screenOrientation="portrait"
            android:label="@string/lbActTerms">
        </activity>

        <!-- About Activity -->
        <activity            
            android:name=".AboutActivity"
            android:screenOrientation="portrait"
            android:label="@string/lbActAbout">
        </activity>

        <!-- Donation Activity -->
        <activity            
            android:name=".DonationActivity"
            android:screenOrientation="portrait"
            android:label="@string/lbActDonation">
        </activity>

        <!-- Image Upload Activity -->
        <activity                        
            android:name=".photo.ImageUploadActivity"
            android:screenOrientation="portrait"
            android:label="@string/lbActUpload" 
            android:configChanges="orientation|keyboardHidden|screenSize">
        </activity>

        <!-- Me Detail Activity -->
        <activity            
            android:name=".photo.MeDetailActivity"
            android:label="@string/lbActCollection"
            android:parentActivityName=".DashboardActivity"            
            android:configChanges="orientation|keyboardHidden|screenSize">

            <Meta-data android:name="android.support.PARENT_ACTIVITY"
                       android:value=".DashboardActivity" />
        </activity>

        <!-- Explore Detail Activity -->
        <activity            
            android:name=".photo.ExploreDetailActivity"
            android:label="@string/lbActExplore"
            android:parentActivityName=".DashboardActivity"            
            android:uiOptions="splitActionBarWhenNarrow"
            android:configChanges="orientation|keyboardHidden|screenSize">

            <Meta-data android:name="android.support.PARENT_ACTIVITY"
                       android:value=".DashboardActivity" />
        </activity>

        <!-- Liked Detail Activity -->
        <activity            
            android:name=".photo.LikedDetailActivity"
            android:label="@string/lbActLikes"
            android:parentActivityName=".DashboardActivity"            
            android:configChanges="orientation|keyboardHidden|screenSize">

            <Meta-data android:name="android.support.PARENT_ACTIVITY"
                       android:value=".DashboardActivity" />
        </activity>

    </application>

</manifest>

解决方法

尝试用android.hardware.camera更改android.hardware.CAMERA.然后

For any of the permissions below,you can disable filtering based on
the implied feature by explicitly declaring the implied feature
explicitly,in a element,with an
android:required=”false” attribute.

而根据permissions features,你没有添加功能android.hardware.camera.autofocus.

因此,添加功能或更改您的相机权限:

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

希望它的作品:)

原文链接:https://www.f2er.com/android/313062.html

猜你在找的Android相关文章