【发布时间】:2015-03-07 22:12:12
【问题描述】:
我们的 Phonegap 混合应用程序在首次加载时运行良好。在这种情况下,很明显 deviceready 事件正确触发并且应用程序启动了。没有问题。
我们需要在某个时候重新加载应用程序。我们只需在 index.html(主应用程序 html 文件)上执行 location.reload()。这是 ios 7 设备中问题开始的地方。应用程序未启动,并且似乎未触发 deviceready。
我的问题是:
1) In ios 7 devices, is the deviceready fired only once?
2) If it is so, how can we catch it when we reload the application?
我们在安卓设备中没有这个问题。
【问题讨论】:
-
Vijey,在 iOS 6 中重新加载后它可以工作吗?我找到了这个,它适用于特定版本的 Cordova。 issues.apache.org/jira/browse/CB-5037
-
Jason,它在 IOS 6 中运行良好