• 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: Clicking checkbox in outline view without selecting row
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Clicking checkbox in outline view without selecting row


  • Subject: Re: Clicking checkbox in outline view without selecting row
  • From: daniel <email@hidden>
  • Date: Thu, 24 Feb 2005 19:15:06 -0800

That does seem tricky. How's this for a strategy?

- Subclass NSOutlineView.
- Implement mouseDown:
	- Get the target cell via columnAtPoint/rowAtPoint.
	- If the target cell is a checkbox button cell, then track it yourself.
	- Otherwise, call through to [super mouseDown].

Daniel

On Feb 24, 2005, at 2:56 AM, Bill Cheeseman wrote:

I have a column of checkboxes in an NSOutlineView. When the user clicks a
checkbox, the row the checkbox is in automatically gets selected.


I would prefer that the user be able to click any checkbox without changing
the current row selection, but I can't find a way to make it work. I've
tried all the obvious delegate methods, but if I prevent the row from being
selected the checkbox never notices that it has been clicked.


Does anyone have a solution? I think I need a mechanism to let the click
pass through the row to the checkbox even though selection of the row is
suppressed by a "should" delegate method.


--

Bill Cheeseman - email@hidden
Quechee Software, Quechee, Vermont, USA
http://www.quecheesoftware.com

PreFab Software - http://www.prefab.com/scripting.html
The AppleScript Sourcebook - http://www.AppleScriptSourcebook.com
Vermont Recipes - http://www.stepwise.com/Articles/VermontRecipes


_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
sweater.com


This email sent to email@hidden

_______________________________________________ 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: 
 >Clicking checkbox in outline view without selecting row (From: Bill Cheeseman <email@hidden>)

  • Prev by Date: Re: NSTask not using arguments?
  • Next by Date: Re: NSArchiving and NSUnarchiving multiple objects
  • Previous by thread: Clicking checkbox in outline view without selecting row
  • Next by thread: NSView isFlipped & NSBitmapImageRep
  • Index(es):
    • Date
    • Thread