I have a Push-notification app. I create intent for click on notificaion:
Intent open = new Intent();
open.setAction("com.bupyc.pushall.app.OPEN");
open.putExtra("url", url);
open.putExtra("lid", lid);
open.putExtra("regId", regId);
PendingIntent contentIntent = PendingIntent.getBroadcast(this.getApplicationContext(), 0, open, PendingIntent.FLAG_CANCEL_CURRENT);
And in manifest
<receiver android:name=".OpenBroadcastReceiver">
<intent-filter>
<action android:name="com.bupyc.pushall.app.OPEN" />
</intent-filter>
</receiver>
But if i send more 1 notification intent does not work. Its work only for first notification
If problem with "PendingIntent.FLAG_CANCEL_CURRENT" how intent multiple broadcast intent with other url, lid extras?
Aucun commentaire:
Enregistrer un commentaire