• 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
NSArrayController -- will change selection?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

NSArrayController -- will change selection?


  • Subject: NSArrayController -- will change selection?
  • From: Stuart Malin <email@hidden>
  • Date: Sat, 7 Mar 2009 14:38:58 -1000

I've got a preferences view that is a kin to Mail's for its accounts, and I'd like it to behave the same.

I am using an NSArrayController to manage a table list of accounts. There are a variety of account datum presented in NSTextFields. These fields are bound to the controller. I am able to track if changes to the presently selected account are made. Now, if the user changes the selection, I need to display an alert sheet asking if changes should be saved. That sheet needs to be presented *before* the selection is actually changed, because one of the alert sheet options (a la Mail) is Cancel. Alas, I am presently only able to detect that the array controller has changed the selection, not will change, and further have no way to prevent that change. I've been searching archives and reading documentation regarding to NSArrayController, but haven't some upon any insight into how to solve my problem. What I'd really like is to discover that the array controller has functionality similar to - (BOOL) willChangeSelection and -(void)DidChangeSelection. Does such exist and I've just missed it?
_______________________________________________


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: NSArrayController -- will change selection?
      • From: Kyle Sluder <email@hidden>
  • Prev by Date: Re: NSOperation and NSAutoreleasePool
  • Next by Date: NSString to Integer
  • Previous by thread: Re: Cleaner daemon managed by Launchd?
  • Next by thread: Re: NSArrayController -- will change selection?
  • Index(es):
    • Date
    • Thread