Android工作室“无法解析符号mapactivity”

时间:2015-06-10 18:10:49

标签: android android-studio

我刚刚导入了一个正在编译的项目,并且正常从Eclipse运行到AS。我有一个Wakefulbroadcast接收器和intentservice嵌套在mapactivity中。该应用程序编译但我在清单中的mapactivity下有红色波浪线显示“无法解析符号mapactivity”。是什么造成的?

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

    <uses-sdk
        android:minSdkVersion="11"
        android:targetSdkVersion="22" />
    <library />
    <uses-permission android:name="android.permission.ACCESS_NETWORK_STATE"/>
    <uses-permission android:name="android.permission.ACCESS_FINE_LOCATION"/>
    <uses-permission android:name="android.permission.ACCESS_WIFI_STATE"/>
    <uses-permission android:name="android.permission.BATTERY_STATS"/>
    <uses-permission android:name="android.permission.INTERNET"/>
    <uses-permission android:name="android.permission.CALL_PHONE" />
    <uses-permission android:name="android.permission.PROCESS_OUTGOING_CALLS"/>
    <uses-permission android:name="android.permission.RECEIVE_SMS"/>
    <uses-permission android:name="android.permission.SEND_SMS"/>
    <uses-permission android:name="android.permission.WRITE_SMS" />
    <uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE"/>
    <uses-permission android:name="com.google.android.providers.gsf.permission.READ_GSERVICES"/>
    <uses-permission android:name="mypackage.permission.MAPS_RECEIVE"/>
    <uses-permission android:name="android.permission.WAKE_LOCK"/>
    <uses-permission android:name="mypackage.permission.C2D_MESSAGE" />
    <uses-permission android:name="myotherpackage.permission.C2D_MESSAGE" />
    <uses-permission android:name="android.permission.GET_ACCOUNTS"/> 
    <uses-permission android:name="com.google.android.c2dm.permission.RECEIVE" /> 
    <uses-permission android:name="android.permission.GET_ACCOUNTS" />
    <uses-feature
        android:glEsVersion="0x00020000"
        android:required="true"/>

    <permission
        android:name="mypackage.permission.MAPS_RECEIVE"
        android:protectionLevel="signature" />
    <permission 
        android:name="com.google.android.c2dm.permission.RECEIVE"></permission>
    <permission 
        android:name="mypackage.permission.C2D_MESSAGE"
        android:protectionLevel="signature"></permission> 

    <application
        android:allowBackup="true"
        android:icon="@drawable/taximdpi"
        android:label="@string/app_name"
        android:theme="@style/AppTheme" >

        <meta-data android:name="com.google.android.gms.version"
        android:value="@integer/google_play_services_version" />
        <meta-data
        android:name="com.google.android.maps.v2.API_KEY"
        android:value="myapikey"/>
        <activity
            android:name=".MainActivity"
            android:label="@string/app_name" >
            <intent-filter>
                <action android:name="android.intent.action.MAIN" />

                <category android:name="android.intent.category.LAUNCHER" />
            </intent-filter>
        </activity>

        <activity
            android:name=".MapActivity"
            android:label="@string/app_name" >
            <intent-filter>
                <action android:name="android.intent.action.MAPACTIVITY" />

                <category android:name="android.intent.category.DEFAULT" />
            </intent-filter>
        </activity>
        <receiver
            android:name=".MapActivity.GCMBroadcastReceiver"
            android:permission="com.google.android.c2dm.permission.SEND" >
            <intent-filter>
        <!--Receives the actual messages. -->
                <action android:name="com.google.android.c2dm.intent.RECEIVE" />
        <!--Receives the registration id. -->
                <action android:name="com.google.android.c2dm.intent.REGISTRATION" />
                <category android:name="mypackage" />
                <category android:name="myotherpackage" />
            </intent-filter>
        </receiver>
        <service android:name=".MapActivity.GCMIntentService" />

    </application>

</manifest>

0 个答案:

没有答案