• 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
Bindings Question: Master-Detail across windows/nibs
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Bindings Question: Master-Detail across windows/nibs


  • Subject: Bindings Question: Master-Detail across windows/nibs
  • From: Chip Coons <email@hidden>
  • Date: Fri, 15 Apr 2005 18:27:30 -0500

I've got an application that uses bindings to manage a list of objects via NSArrayController.

I want to implement an inspector window that shows the details of the selected object in a list.  My list displays the object name property with a status.

The inspector window is in a separate nib file.  

Within the -(void)awakeFromNib method of the inspector window controller object I programatically create the binding between the NSArrayController.selection in my main document window and the interface elements in the inspector window using the bind:toObject:withKeyPath:options: method.  i.e.

    [nameText bind:@"value" toObject:parentController
           withKeyPath:@"selection.objectName" options:nil];



When the inspector window displays the first time, behavior is as expected, i.e. I can edit the name in the inspector and have it update the Master listing and underlying model object correctly.

However,  if I select another name on the list in the master window, the inspector does not update.  It doesn't work if I close the inspector and re-open with a different item selected either.

Any suggestions on alternative approaches would be appreciated.

-Chip Coons
 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Prev by Date: Calling a void from another controller
  • Next by Date: Re: Applying a transparent color over an image
  • Previous by thread: Calling a void from another controller
  • Next by thread: Getting list-size (16 x 16) document icon for list
  • Index(es):
    • Date
    • Thread