• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: NSObjectController and NSDefaultsController Binding?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: NSObjectController and NSDefaultsController Binding?


  • Subject: Re: NSObjectController and NSDefaultsController Binding?
  • From: Bruce Truax <email@hidden>
  • Date: Sun, 18 Apr 2004 07:35:28 -0400

On 4/18/04 2:47 AM, "Scott Anguish" <email@hidden> eloquently wrote:

>
> On Apr 17, 2004, at 5:53 PM, Bruce Truax wrote:
>
>> Is it possible to use both an NSObjectController and
>> NSDefaultsController to
>> bind the value of a NETextEdit field to your model object and the
>> defaults
>> controller simultaneously? If the answer is yes, are there any special
>> tricks to make this work? It looks to me like you can only select one
>> type
>> of binding for the value parameter at a time.
>>
>
> While mmalc said it's not possible (which is true), my question would
> be what are you trying to accomplish?
>
> this sounds like it might be either a job for a placeholder, or using
> NSUserDefaultsController exclusively, but setting the 'default default
> values' in the registration domain.
>
>

My application uses numerous dialog boxes which require the user to set
options and enter parameter data. I want all of these settings and data to
be persistent between sessions so I want to save them as User Defaults.
This is simple with NSUserDefaultsController. It would also be nice if the
variables in the model object were automatically updated as the user
modified the dialog. If I had to only select one of the controllers I would
use NSUserDefaultsController because it eliminates more lines of code in my
model object but if I could do both the amount of code I would have to write
for each dialog would be reduced dramatically.

Bruce
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.


  • Follow-Ups:
    • Re: NSObjectController and NSDefaultsController Binding?
      • From: Allan Odgaard <email@hidden>
References: 
 >Re: NSObjectController and NSDefaultsController Binding? (From: Scott Anguish <email@hidden>)

  • Prev by Date: Re: Array controller?
  • Next by Date: Remove field editor's cursor region?
  • Previous by thread: Re: NSObjectController and NSDefaultsController Binding?
  • Next by thread: Re: NSObjectController and NSDefaultsController Binding?
  • Index(es):
    • Date
    • Thread