Android的手机短信意图聊2.0 [英] Android SMS Intent Hangouts 2.0

查看:100
本文介绍了Android的手机短信意图聊2.0的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

随着视频群聊2.0的谷歌已经打破(或无证)如何从第三方应用通过意向发送短信的身体。

As of Hangouts 2.0 Google have broken (or undocumented) how to send SMS body from third party apps via Intent.

这使得从您的应用程序上通过有意发送短信4.4彻底打破。

This renders Sending SMS via an intent from your app on 4.4 completely broken.

下面的意图不工作:

Intent smsIntent = new Intent(Intent.ACTION_SENDTO);
smsIntent.setType("vnd.android-dir/mms-sms");
smsIntent.putExtra("address", "12125551212");
smsIntent.putExtra("sms_body","Body of Message");\

Intent sendIntent = new Intent(Intent.ACTION_SENDTO);         
sendIntent.setData(Uri.parse("sms:"));
sendIntent.putExtra("sms_body", x); 

聊完全忽略的setType(vnd.android-DI​​R / MMS,SMS)

回落至 Uri.parse 的方法是唯一的选择,但应用程序还是会忽略 sms_body 键。

Falling back to the Uri.parse method is the only option, but the app still ignores sms_body key.

目前这个时间点上的无证这样玩弄的%的身体%来没有修成正果一些变化。

At this point in time its undocumented so playing around with a few variations of %body% to no fruition.

值得注意的,我们试图 http://www.ietf.org/rfc/rfc5724.txt 创建一个URI按照规范。 短信:12345666777身体=这里文本,但没有帮助有

Worth noting we tried http://www.ietf.org/rfc/rfc5724.txt to create a URI as per the spec. sms:12345666777?body=Text here but no help there.

*注:我是用ACTION_VIEW,改为ACTION_SENDTO,依然无果*

*Note: I was using ACTION_VIEW, changed to ACTION_SENDTO, still to no avail*

推荐答案

这是固定的去处2.0.128(2013年11月16日)

This was fixed in hangouts 2.0.128 (2013-11-16)

值得关注的只有 ACTION_VIEW ACTION_SENDTO 这两个现在的工作。

Worth noting only ACTION_VIEW and ACTION_SENDTO both work now.

这篇关于Android的手机短信意图聊2.0的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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