Android AlarmClock按标签搜索 [英] Android AlarmClock search by label

查看:95
本文介绍了Android AlarmClock按标签搜索的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想将Intent与 android.provider.AlarmClock

I want to use an Intent with android.provider.AlarmClock to dismiss (ACTION_DISMISS_ALARM) an specific Alarm. I want to use ALARM_SEARCH_MODE_LABEL to select the alarm. However, I have no idea how I can set the label to search for.

Intent i = new Intent(AlarmClock.ACTION_DISMISS_ALARM);
i.putExtra(AlarmClock.EXTRA_ALARM_SEARCH_MODE, AlarmClock.ALARM_SEARCH_MODE_LABEL);
startActivity(i);

有人可以帮我完成代码吗?

Can someone help me complete the code?

推荐答案

似乎是:

intent.putExtra(AlarmClock.EXTRA_MESSAGE, label)

这似乎导致删除带有该标签的条目.

This seems to result in deleting the entry with that label.

这篇关于Android AlarmClock按标签搜索的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆