I’ve been doing some Android Widgets tutorials, and learning Kotlin at the same time.
I have successfully set up a widget with a button and a notification for that button which does some code and then updates the widget.
When trying to add a second widget, and trying to add another intent notification, I see that the first button now updates the second widget. It’s as if the notification I set up in the second button updates and overwrites the first notification.
I am using the standard PendingIntent.getBroadcast(
[..]_UPDATE or _IMMUTABLE)
functionality, with a new intent created each time, for setting up the notification firing.
I haven’t had a chance to test, should I remove the IMMUTABLE
flag from my code?
I can provide some code tomorrow.