Xcode 6 iOS模拟器不记得应用程序设置 [英] Xcode 6 iOS Simulator does not remember app settings

查看:143
本文介绍了Xcode 6 iOS模拟器不记得应用程序设置的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我刚刚安装了Xcode 6.0.1(来自Xcode 5.1.1)并尝试在iPhone 6模拟器上首次运行我的iOS应用程序。它构建并运行,但我无法更改其设置。我使用 NSUserDefaults 进行设置。每次更改设置时,请返回设置列表,然后再次选择我的应用程序设置,它们将根据默认设置进行设置。

I just installed Xcode 6.0.1 (coming from Xcode 5.1.1) and tried to run my iOS app on iPhone 6 simulator for the first time. It builds and runs, but I cannot change its settings. I use NSUserDefaults for my settings. Each time I change settings, go back to the list of settings and then select my app's settings again, they are set according to the default settings.

当我试图计算时为什么会发生这种情况我注意到更改标准iOS应用程序地图的设置也不起作用。我无法将距离设置从英里改为公里。在模拟iPhone 6和iPhone 6 plus时,会在新的iOS模拟器设置(我多次重置内容和设置)时发生这种情况。

When I tried to figure out why this could happen I noticed that changing settings of the standard iOS app Maps does not work either. I cannot change the distance setting from miles to kilometers. This happens with fresh iOS Simulator settings (I "Reset Content and Settings" several times) when simulating iPhone 6 and iPhone 6 plus.

任何想法?

推荐答案

这是模拟器中iOS 8.0中的已知错误。目前唯一的解决方法是使用defaults命令行工具从命令行设置首选项。

This is a known bug in iOS 8.0 in the simulator. The only workaround at this time is to set the preferences from the command line using the defaults command line tool.

defaults write ˜/Library/Developer/CoreSimulator/Devices/<UDID>/data/Containers/Data/Application/<App UUID>/Library/Preferences/...

您还需要找到相关的UDID。

You also need to find the relevant UDID.

这篇关于Xcode 6 iOS模拟器不记得应用程序设置的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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