本文介绍了位置服务指示器保持“开启”状态的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我创建了一个使用iPhone上的位置服务的小应用程序。一切都运作良好,除了事实,有时,即使我明确杀死应用程序,信息栏中的小箭头仍保持活动状态。
我使用locationservices的后台模式,因此appDelegate方法 applicationWillResignActive applicationDidEnterBackground applicationWillEnterForeground applicationDidBecomeActive 已实现但不接触位置服务(好吧 - 我在后台模式下需要它们)。

I have a created a small app which uses location services on the iPhone. All works well, except the fact, that sometimes, the small arrow in the info-bar stays active even if I explicitly kill the app.I use the background mode for locationservices, thus the appDelegate methods applicationWillResignActive, applicationDidEnterBackground, applicationWillEnterForeground and applicationDidBecomeActive are implemented but do not touch the location services (well - I need them in background mode).

在该配置中,永远不会调用 applicationWillTerminate ;我在 dealloc 中将所有清理清理实现为 stopUpdatingLocation ,因为我没有找到任何适合此的其他地方。但仍然 - 指标仍然存在。

In that configuration applicationWillTerminate is never called; I implemented all the cleanup cleanup as stopUpdatingLocation in dealloc, as I did not find any other place appropriate for this. But still - the indicator stays on.

任何想法?

推荐答案

好的,问题解决了。指示灯将保持亮起,直到找到新位置。然后,如果其他一切都正确,指示灯将熄灭。

Ok, problem solved. The indicator will stay on until a new location is found. Then if everything else is correct, the indicator turns off.

这篇关于位置服务指示器保持“开启”状态的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

09-02 12:03