Userdefaults, their initial values, and bindings
Userdefaults, their initial values, and bindings
- Subject: Userdefaults, their initial values, and bindings
- From: Francis Derive <email@hidden>
- Date: Mon, 20 Aug 2007 16:51:15 +0200
Hello world,
I used bindings to bind, in IB, colorWells values of a preferences
panel to a shared instance of NSUserDefaultsController.
Well made without doing much.
What about initial values of these defaults ?
From "User Defaults and Bindings"docs @ ADC Home > Reference Library
> Guides > Cocoa > Design Guidelines > Cocoa Bindings Programming
Topics >, the code of Listing 2 Changing the initial values of the
sharedUserDefaultsController instance shows :
// load the default values for the user defaults
userDefaultsValuesPath=[[NSBundle mainBundle]
pathForResource:@"UserDefaults"
ofType:@"plist"];
but this gives null for my app.
If something of my defaults are stored on disk, it is at ~/Library/
Preferences/com.myApp.plist.
Why this difference ? no "UserDefaults" resource in my app bundle -
is it because, using bindings for userdefaults, I didn't
registerDefaults: ?
What can I do as it is ?
Francis
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden