拨号号码不及时及时、号码

2023-09-12 22:32:42 作者:拱手江山讨你欢

我想编写一个函数为Android平台,让我打911没有任何形式的提示。

I'm trying to write a function for the Android platform that will allow me to call 911 without any sort of prompt.

我已经添加的权限 android.permission.CALL_PRIVILEGED 。我只是需要将拨打911在我的选项菜单按钮的preSS的功能。

I have already added the permission android.permission.CALL_PRIVILEGED. I just need a function that will dial 911 at the press of a button in my options menu.

推荐答案

根据API,ACTION_CALL会做你的需要,但不紧急号码,而ACTION_DIAL将显示与拨号提示拨号器,但允许拨打紧急电话号码。

According to the API, ACTION_CALL will do what you need but not to emergency numbers, while ACTION_DIAL will display a dialer with the dial prompt but allows to call emergency numbers.

恐怕是没有办法做你想做的,一个很好的理由 - 以prevent拨错紧急服务。这是一个precautionary措施。

I'm afraid there is no way to do what you want, for a good reason - to prevent misdials to emergency services. It's a precautionary measure.