简体   繁体   English

检查设备上是否启用了facetime

[英]Check if facetime is enabled on the device

The app we're building has a simple button that starts a facetime session with a specific number. 我们正在构建的应用程序有一个简单的按钮,可以启动具有特定号码的临时会话。 No biggee here. 这里没有大事。

I use 我用

[[UIApplication sharedApplication] canOpenURL: [NSURL URLWithString: @"facetime://5555555555"]];

to check if the device is capable of facetime calls. 检查设备是否能够进行临时呼叫。 Again, this works fine. 再次,这很好。

But a user can turn facetime on/off through the settings screen of his device. 但是用户可以通过其设备的设置屏幕打开/关闭面部时间。 When facetime is turned off the above canOpenURL method still returns YES even though facetime is disabled. 当facetime关闭时,即使禁用了facetime,上面的canOpenURL方法仍会返回YES And when I start a new session through the openURL method the screen simply goes to my contactlist without starting a facetime session. 当我通过openURL方法开始一个新会话时,屏幕只会转到我的联系人列表而不启动facetime会话。

Anyone know if it's possible to determine if facetime is enabled on the device. 任何人都知道是否可以确定设备上是否启用了facetime。

Unfortunately, there is no way that you can detect if FaceTime has been enabled or disabled (as of iOS 5.1). 不幸的是,您无法检测FaceTime是否已启用或禁用(从iOS 5.1开始)。 Sorry. 抱歉。

As for... 至于...

facetime://5555555555

...according to this Apple Developer forum post, Apple rejects apps that uses undocumented APIs, and FaceTime is one of them. ...根据Apple开发者论坛帖子,Apple拒绝使用未记录的API的应用程序,而FaceTime就是其中之一。 Look at the fourth post. 看看第四篇文章。

This is the link that the person was talking about. 是该人正在谈论的链接。

There is probably another way around it, but I can't think of anything right now. 可能还有另外一种方法,但我现在想不出任何东西。 Hopes this helps answer your question. 希望这有助于回答您的问题。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM