• 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: Controllers and Views
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Controllers and Views


  • Subject: Re: Controllers and Views
  • From: mmalcolm crawford <email@hidden>
  • Date: Thu, 15 Jul 2004 18:20:58 -0700

On Jul 15, 2004, at 5:35 PM, Tim Conkling wrote:

The magical part that I can't quite wrap my head around is that, when the NSArrayController has an object added to or deleted from it, the NSTableView immediately reflects the changes, though I never made any binding from NSArrayController to the NSTableView. How does the array know about the table view? Do bindings somehow work both ways automatically?

Bi-directional synchronisation is the main feature of Cocoa bindings. The array does not, though, know about the table view; the array controller is responsible for manipulating the array using key-value coding (typically via suitable accessor methods implemented by the object that contains the array). See:

<http://developer.apple.com/documentation/Cocoa/Conceptual/ CocoaBindings/Concepts/WhatAreBindings.html>
and
<http://developer.apple.com/documentation/Cocoa/Conceptual/ CocoaBindings/Concepts/HowDoBindingsWork.html>

mmalc
_______________________________________________
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.


References: 
 >Controllers and Views (From: Tim Conkling <email@hidden>)

  • Prev by Date: Changing Cell Size in at TableView?
  • Next by Date: Re: Applescript error - NSCannotCreateScriptCommandError
  • Previous by thread: Controllers and Views
  • Next by thread: Re: Controllers and Views
  • Index(es):
    • Date
    • Thread