Thanks a lot for your explanation :-)

Cheers,
Jochen


Am 04.06.2008 um 11:21 schrieb Ken Thomases:

On Jun 4, 2008, at 3:18 AM, Jochen Moeller wrote:

I already read this link and thought that the NSArrayController "Mailbox" represents this intervening NSController between the model object and the table view because the table view is not bound direct to the model or a custom controller. To reformulate my question - Why is a second intervening NSController in form of an NSObjectController useful?

I believe (although I'm not certain) that it allows a single place to send the -commitEditing message to commit the editing of all relevant views, chained through the array controllers. Without that single object controller, you'd have to send -commitEditing to each of the array controllers separately.

Also, there's no downside to using the NSObjectController. It may have just been the author's habit. It might be considered future- proofing.

As you note, it's not strictly necessary in that example.

Regards,
Ken

_______________________________________________

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

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:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to [EMAIL PROTECTED]

Reply via email to