gpt4 book ai didi

android - Google Keep 在您的应用程序中列出备注

转载 作者:行者123 更新时间:2023-11-30 02:03:08 29 4
gpt4 key购买 nike

在我的应用中,我正在编写一个功能来将购物 list 分享到 Google Keep。为此,我使用 Intent.ACTION_SEND 操作并将包设置为 Google Keep 之一。

一切正常,但我想知道是否可以向 Intent 添加一个 EXTRA 参数,告诉 Google Keep 它必须显示为带有复选框的列表,就像在创建日历事件。现在,它显示为纯文本。

这是我的代码:

try {
Intent keepIntent = new Intent(Intent.ACTION_SEND);
keepIntent.setType("text/plain");
keepIntent.setPackage("com.google.android.keep");

keepIntent.putExtra(Intent.EXTRA_SUBJECT, "Shopping List " + recipe.getName());
keepIntent.putExtra(Intent.EXTRA_TEXT, "Flower\nyeast\nbutter\nalmonds");

startActivity(keepIntent);
} catch (Exception e) {
Dialogs.toastShort(this, "Google Keep is not installed on your device");
}

现在,我得到了这个结果:

enter image description here

我想得到的是这个结果——否则用户必须在操作栏中选择“显示复选框”:

enter image description here

感谢您的帮助。

最佳答案

很遗憾,这是不可能的。 Google 尚未发布供公众或第 3 方使用的 API。如果您检查 http 流量,您可以看到底层 API,但没有真正的方法来复制它。抱歉

关于android - Google Keep 在您的应用程序中列出备注,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/31168947/

29 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com