• 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: How to set a mixed checkbox?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: How to set a mixed checkbox?


  • Subject: Re: How to set a mixed checkbox?
  • From: Greg Titus <email@hidden>
  • Date: Sat, 10 Jun 2006 15:56:55 -0700


On Jun 10, 2006, at 15:31 , email@hidden wrote:

In my NSOutlineView, I have a series of checkboxes ( [buttonCell setButtonType: NSSwitchButton], where "buttonCell" is an NSButtonCell), however, I can't seem to set a mixed state. In my - (id)outlineView:(NSOutlineView *)olv objectValueForTableColumn: (NSTableColumn *)tableColumn byItem:(id)item

I do a:
		objectValue					= [NSNumber numberWithInt: [node mRunState]];

If I return a 0, the checkbox turns off, a 1 on. However, if I return a -1 (NSMixedState), the checkbox stays on (instead of the horizontal bar "mixed" state).

How do I set a mixed state?

Thanks!

This may be a dumb question, but did you call - setAllowsMixedState:YES on your buttonCells when setting them up?


Hope this helps,
	- Greg
_______________________________________________
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: How to set a mixed checkbox?
      • From: "email@hidden" <email@hidden>
References: 
 >How to set a mixed checkbox? (From: "email@hidden" <email@hidden>)

  • Prev by Date: How to set a mixed checkbox?
  • Next by Date: Re: How to set a mixed checkbox?
  • Previous by thread: How to set a mixed checkbox?
  • Next by thread: Re: How to set a mixed checkbox?
  • Index(es):
    • Date
    • Thread