I've implemented GCM in my app, following this official tutorial.
But my users under Android 4.0.3 reported me notifications are not working. I found out that onReceive
from my GcmBroadcastReceiver extends BroadcastReceiver
wasn't fired.
Here is my Manifest.
<!-- GCM -->
<uses-permission android:name="android.permission.GET_ACCOUNTS" />
<uses-permission android:name="com.google.android.c2dm.permission.RECEIVE" />
<uses-permission android:name="android.permission.VIBRATE" />
<permission
android:name="com.myapp.gcm.permission.C2D_MESSAGE"
android:protectionLevel="signature" />
<uses-permission android:name="com.myapp.gcm.permission.C2D_MESSAGE" />
<application
... >
<!-- GCM -->
<receiver
android:name="com.myapp.GcmBroadcastReceiver"
android:permission="com.google.android.c2dm.permission.SEND" >
<intent-filter>
<action android:name="com.google.android.c2dm.intent.RECEIVE" />
<category android:name="com.myapp" />
</intent-filter>
</receiver>
What am I doing wrong?