调用stopUpdatingLocation后,位置指示器在状态栏上仍然存在,但仅适用于旧的Bundle Identifier [英] Location indicator persists on status bar after stopUpdatingLocation is called, but only for old Bundle Identifier

查看:465
本文介绍了调用stopUpdatingLocation后,位置指示器在状态栏上仍然存在,但仅适用于旧的Bundle Identifier的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

是否有人知道为什么位置指示器会保留某些捆绑标识与其他标识符?
我正在使用Apple示例LocateMe应用程序,安装在运行5.0.1版的iOS设备上。当我使用旧的包标识符时,位置指示符保持在状态栏上,在调用CLLocationManager stopUpdatingLocation之后。

Does any one know why the location indicator stay on for certain bundle identifer vs. the others? I am using an Apple sample LocateMe app, installed on my iOS device running version 5.0.1. When I'm using an old bundle identifier, the location indicator stays on the status bar, after the CLLocationManager stopUpdatingLocation is being call.

但是,当我使用同样精确的应用程序,唯一的区别是新的捆绑ID,应用程序按预期工作,并且一旦调用stopUpdatingLocation,位置指示符就会消失。

But, when I'm using the same exact app, with the only difference being a new bundle id, the app works as expected and the location indicator disappear once the stopUpdatingLocation is being called.

有没有人遇到此问题问题还是可以解释一下?

Did anyone experience this problem or can explain it?

推荐答案

我终于想到如果我从设置中重置位置警告,则该错误消失。

I finally figured that if I reset the Location Warnings from the Settings, the bug disappear.

从iOS设置中选择常规|重置|重置位置警告。这会将警告重置为所有应用程序。这意味着下次启动需要位置的应用时,iOS会提示您使用位置权限对话框。
从操作表中选择重置警告。

From your iOS Settings select General | Reset | Reset Location Warnings. This will reset the warning to all the apps. This mean that the next time you start an app that requires location, the iOS will prompt you with the location permission dialog. Select 'Reset Warnings' from the action sheet.

再次运行应用程序时,iOS会提示您使用位置权限对话框(如果没有 - 重复上述过程以重置位置警告)。选择是后,应用程序按预期运行,几秒钟后位置指示符消失。

When running the app again, the iOS will prompts you with the location permission dialog (if it doesn't - repeat the process above to reset the location warnings). After selecting yes, the app behaves as expected, and the location indicator disappears after few seconds.

这篇关于调用stopUpdatingLocation后,位置指示器在状态栏上仍然存在,但仅适用于旧的Bundle Identifier的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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