How to check if alarm is set

后端 未结 3 1418
眼角桃花
眼角桃花 2021-02-06 05:50

I\'m trying to check if my alarm is active or not. The alarmIsSet method will return false before the alarm is set, true when the alarm is set. So far so good, however, after th

3条回答
  •  攒了一身酷
    2021-02-06 06:15

    After having some headaches with this stuff myself, I found out that if I somehow had created a pending intent while testing stuff, that it actually was not cleared between tests. Even killing the app didn't do it. The intent still stayed in the system and kept returning true when checking for it. I actually had to write some code to kill it before it tested right.

提交回复
热议问题