I have a custom button in a sticky notification.
I used to attach a PendingIntent
to it for receiving button clicks:
Intent intent = new I
Never use an implicit Intent
when an explicit Intent
will work.
Replace:
Intent intent = new Intent();
intent.setAction("com.example.app.intent.action.BUTTON_CLICK");
with:
Intent intent = new Intent(this, NotificationActionReceiver.class);
And remove the
from the NotificationActionReceiver
element.