0
嗨大家我在我的清單文件有問題,說不能識別android:name=".GcmBroadcastReceiver"
和<service android:name=".GcmIntentService" />
,我definetly找不到解決方案,我真的需要幫助,我已經安裝所有谷歌播放服務,也是我的gradle與未來依賴更新:GcmBroadcastReceiver無法解決問題(andorid studio)
compile 'com.android.support:appcompat-v7:22.0.0',
compile 'com.google.android.gms:play-services:7.0.0'
compile "com.google.android.gms:play-services-gcm:7.0.0"
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.example.pedrobal.chatonline" >
<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.GET_ACCOUNTS" />
<uses-permission android:name="android.permission.WAKE_LOCK" />
<uses-permission android:name="com.google.android.c2dm.permission.RECEIVE" />
<permission
android:name="com.example.pedrobal.chatonline.permission.C2D_MESSAGE"
android:protectionLevel="signature" />
<uses-permission android:name="com.appsrox.instachat.permission.C2D_MESSAGE" />
<application
android:allowBackup="true"
android:icon="@mipmap/ic_launcher"
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" />
<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>
<receiver
android:name=".GcmBroadcastReceiver"
android:permission="com.google.android.c2dm.permission.SEND" >
<intent-filter>
<action android:name="com.google.android.c2dm.intent.RECEIVE" />
<category android:name="com.example.pedrobal.chatonline" />
</intent-filter>
</receiver>
<service android:name=".GcmIntentService" />
</application>
</manifest>