Ray's playground

 

User Defaults(Chapter 13 of Cocoa Programming for Mac OS X)

Every application comes with a set of defaults from the factory. When a user edits his or her defaults, only the differences between the user's wishes and the factory defaults are stored in the user's defaults database. Thus, every time the application starts up, you need to remind it of the factory defaults. This operation is called registering defaults.

After registering, you will use the user defaults object to determine how the user wants the app to behave. This process is called reading and using the defaults. The data from the user's defaults database will be read automatically from the filesystem.

posted on 2011-02-22 13:27  Ray Z  阅读(155)  评论(0编辑  收藏  举报

导航