• 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: Read-only NSTableView bindings - forcing update [partially solved]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Read-only NSTableView bindings - forcing update [partially solved]


  • Subject: Re: Read-only NSTableView bindings - forcing update [partially solved]
  • From: Andrew White <email@hidden>
  • Date: Wed, 11 May 2005 12:30:08 +1000


Found the documentation pages on key-value observing. documentation/Cocoa/Conceptual/KeyValueObserving/index.html

These allowed me to figure out willChangeValueForKey and didChangeValueForKey, and thus get the updating all working right.

However, I initially tried to use

+ (void) initialize
{
	[self setKeys: [NSArray arrayWithObject: @"myUnderlyingArray"]
		triggerChangeNotificationsForDependentKey: @"myEntries"
	];
}

- (NSArray *) myEntries
{
	return myUnderlyingArray;
}

This did not seem to trigger the correct notifications for myEntries when I used setArray on myUnderlyingArray. Am I missing something?

Assuming I do it manually rather than via setKeys, do I need to override automaticallyNotifiesObserversForKey: for myEntries to make sure things don't get messed up?

--
Andrew White

--------------------------------------------------------------------------
This email and any attachments may be confidential. They may contain legally
privileged information or copyright material. You should not read, copy,
use or disclose them without authorisation. If you are not an intended
recipient, please contact us at once by return email and then delete both
messages. We do not accept liability in connection with computer virus,
data corruption, delay, interruption, unauthorised access or unauthorised
amendment. This notice should not be removed.
_______________________________________________
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


References: 
 >Read-only NSTableView bindings - forcing update (From: Andrew White <email@hidden>)

  • Prev by Date: Core Image Headless
  • Next by Date: Re: Read-only NSTableView bindings - forcing update
  • Previous by thread: Read-only NSTableView bindings - forcing update
  • Next by thread: Re: Read-only NSTableView bindings - forcing update
  • Index(es):
    • Date
    • Thread