ios 8 openUrl itms-services不会退出当前的应用程序 [英] ios 8 openUrl itms-services does not exit current app

查看:397
本文介绍了ios 8 openUrl itms-services不会退出当前的应用程序的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在iOS 6或7中,当我使用 itms-services:// XXXX 的URL调用UIApplication openUrl时,应用程序将退出到主屏幕以安装新版本我的应用程序(使用带有ipa文件的企业部署)。

In iOS 6 or 7, the app exit to the home screen when I call UIApplication openUrl with a url of itms-services://XXXX to install a new version of my app (using enterprise deployment with ipa files).

在iOS 8中,情况已不再如此。现在应用程序继续运行,就像没有发生任何事情一样,但如果我进入主屏幕,我可以看到我的应用程序图标变灰,下载饼图约66%已完成,文本正在下载.. 。以下。如果我现在等待一段时间(不到一分钟),应用程序安装正确,我可以再次启动我的应用程序。

In iOS 8, this is no longer the case. Now the app continue running just as nothing has happened, but if I go the home screen, I can see my app icon grayed out, with a downloading pie chart about 66% completed and the text "Downloading..." below. If I now wait for a while (less than a minute), the application is installed correctly and I can start my app again.

还有其他人遇到过这种行为吗?有人见过有关此事的任何文件吗?只要记录在案,我就可以接受行为改变,但我没有看到任何关于此的文件。

Has anyone else experienced this behavior? Have anyone seen any documentation regarding this? I can accept behavioral changes as long as it is documented, but I haven't seen any documentation regarding this.

推荐答案

是的,现在在iOS8上单击safari中的下载链接时也会出现相同的行为。

Yes, you also get the same behaviour when clicking a download link in safari now on iOS8.

我不确定为什么他们引入了此更改,但实际上没有办法它周围(除非你强迫你的应用程序崩溃与退出(0);

I'm not sure why they introduced this change but there isn't really a way around it (unless you force your app to crash with something like exit(0);)

此外, itms-services url scheme没有文档,在技术上是私有api。根据经验,您不能将应用程序提交到使用它的App Store。

Also, the itms-services url scheme is undocumented and is technically a private api. From experience, you're not allowed to submit apps to the App Store that use it.

这篇关于ios 8 openUrl itms-services不会退出当前的应用程序的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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