• 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: Binding to selection of NSArrayController
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Binding to selection of NSArrayController


  • Subject: Re: Binding to selection of NSArrayController
  • From: Lee Ann Rucker <email@hidden>
  • Date: Tue, 23 Sep 2014 18:36:50 +0000
  • Thread-topic: Binding to selection of NSArrayController

On Sep 23, 2014, at 9:15 AM, Jonathan Taylor <email@hidden> wrote:
>
>
>
>
> [*] One slight glitch - if I add an object to the NSMutableArray then it does not immediately show up in the table, I have to call will/didChangeValueForKey on the property that returns the array. I don’t know if that is expected behaviour (maybe I should be adding via the array controller somehow?). This is not a problem, but I mention it for completeness, just in case it’s indicative of something funny that is going on that I don’t fully appreciate.

Yes, it’s complicated. The ArrayController doesn’t know about changes that are made directly to the NSMutableArray. You can use [NSArrayController addObject:] for simple cases, or spend a lot of time with the KVC programming guide, especially “Collection accessor patterns for to-many properties”.
_______________________________________________

Cocoa-dev mailing list (email@hidden)

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:

This email sent to email@hidden


  • Follow-Ups:
    • Re: Binding to selection of NSArrayController
      • From: Quincey Morris <email@hidden>
References: 
 >Binding to selection of NSArrayController (From: Jonathan Taylor <email@hidden>)

  • Prev by Date: ios 8 crashing on "_updateInterfaceOrientationFromDeviceOrientation"
  • Next by Date: Re: Binding to selection of NSArrayController
  • Previous by thread: Re: Binding to selection of NSArrayController
  • Next by thread: Re: Binding to selection of NSArrayController
  • Index(es):
    • Date
    • Thread