Is there a way to add a “name” to an ACTION_CALL intent in android?

蹲街弑〆低调 提交于 2019-12-02 07:29:50

Sorry if this answer isn't helpful but:

It's the Phone application which catches the "ACTION_CALL" intent Action. Since this is a device specific app it may vary.

Having a quick google I can't find any information either on what extra's it accepts but I would imagine that injecting a "name" could be considered a security vulnerability and therefore wouldn't be part of the app (however I'm not sure).

Giving your app permissions and functionality to add a contact however (and therefore associating a name with a number) is entirely possible and there are many examples out there on how to interface with the Contacts ContentProvider.

Since the android specification is not mentioning a name parameter on this intent I'd discouarge using it. DOC HERE

Documentation also mentions that most apps should ACTION_DIAL, as ACTION_CALL might have some restrictions on which apps can call it...

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!