What happens if you set the flag on a PendingIntent to 0?

前端 未结 1 1267
失恋的感觉
失恋的感觉 2021-01-02 02:46

What exactly happens when you set the flag on a pending intent to 0? Does it just not raiise a flag or does it default to one of the others?

相关标签:
1条回答
  • 2021-01-02 03:27

    No this is the "default" behavior of creating a new PendingIntent regardless if one already exists or not. If you want more specialized behavior, like cancel an existing PendingIntent if the underlying Intent is the same, or update such an existing PendingIntent, then you should use the various flags you can find in the PendingIntent class.

    0 讨论(0)
提交回复
热议问题