NSTableView binding and clickedRow returning -1
NSTableView binding and clickedRow returning -1
- Subject: NSTableView binding and clickedRow returning -1
- From: Hajder Rabiee <email@hidden>
- Date: Mon, 05 Jan 2015 11:46:16 +0100
Hi
Thought I would post something I see as reoccurring problem.
Basically, having an NSTableView (wrapped in a custom NSView) setup with
bindings works fine. Then,
trying to get the double-action/target in IB working has strange behaviour
when it comes to fetching clickedRow.
*Referring to my own problem at*
http://stackoverflow.com/questions/27740666/nstableview-iboutlet-clickedrow-is-always-1
which has been setup like
https://developer.apple.com/library/mac/qa/qa1472/_index.html
*but also look at these guys*
http://www.cocoabuilder.com/archive/cocoa/201667-nstableview-double-click-binding-and-clickedrow.html
http://www.geektheory.ca/blog/nstableview-and-nsoutlineview-method-clickedrow-always-returning-1-on-double-click-action/
The action target is called but [_tableView clickedRow] always return -1.
Also the parameter for the selector, should it contain all the objects
in the table view or just the clicked row object?
What could be the underlying problem here? There is a good point mentioned
on Stackoverflow that the selector might be called before
the actual selection is done...
--
Med vänliga hälsningar / Best Regards
Hajder
_______________________________________________
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