Android does not need to apply for permission to make calls

There are two ways to make phone calls with Android:

The first method is to make a call and jump to the dialing interface. The source code is as follows:

The second method is to make a call directly. However, some third-party ROMs (such as MIUI) do not make a call directly, but require the user to select whether to make a call. The source code is as follows:

The first method does not need to apply for permission, and you can directly jump to the dialing interface.

The second method needs to add this permission to the androidmenifest file: < uses permission Android: name = "Android. Permission. Call_phone" / >, and in Android 6.0, you need to dynamically apply for permission in the code.

The above is the two ways Android does not need to apply for permission to make calls. I hope it will help you. If you have any questions, please leave me a message and Xiaobian will reply to you in time!

The content of this article comes from the network collection of netizens. It is used as a learning reference. The copyright belongs to the original author.
THE END
分享
二维码
< <上一篇
下一篇>>