• 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
NSMatrix -allowsEmptySelection (but doesn't)
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

NSMatrix -allowsEmptySelection (but doesn't)


  • Subject: NSMatrix -allowsEmptySelection (but doesn't)
  • From: Jeremy Dronfield <email@hidden>
  • Date: Fri, 26 Nov 2004 14:23:32 +0000

Have I misunderstood the documentation on this? According to the NSMatrix docs:

"setAllowsEmptySelection: has an effect only if the selection mode is NSRadioModeMatrix. It lets you choose whether, in a group of radio buttons, it’s allowed for none of them to be on. For example, say the user clicks on the one radio button in a matrix that’s on. If allowsEmptySelection is YES, that button turns off and none of the radio buttons is on."

I have custom matrix with mode set to NSRadioModeMatrix and allowsEmptySelection returning YES which doesn't behave as advertised. When it first loads, it has no cells selected (which is correct), but once a cell has been selected, it can only be unselected by selecting a different one, not by clicking on it again.

Tracking the cell's -state during a click shows that it switches to NSOffState on mouse down, then back to NSOnState on mouse up.

Have I missed something, or is the documentation misleading (or plain wrong)?

Regards,
Jeremy
_______________________________________________
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


  • Follow-Ups:
    • Re: NSMatrix -allowsEmptySelection (but doesn't) -- (kind of solved)
      • From: Jeremy Dronfield <email@hidden>
  • Prev by Date: Using regex.h
  • Next by Date: Using an NSView as a sheet
  • Previous by thread: Re: Using regex.h
  • Next by thread: Re: NSMatrix -allowsEmptySelection (but doesn't) -- (kind of solved)
  • Index(es):
    • Date
    • Thread