Hey is there anyone at all watching this list? Does anyone have any sample code for doing a double click on a list of items? (using the TableView object). I am just hacking up the data access sample and I can't figure out how to respond to a double click.
Yes, I'm here. I haven't figured out how to answer your questions yet, though... Stay tuned.
Thanks Sherm, I very much like this project. I am anxious to put up more examples for folks.
this should be what you want
Daddy-o is right-o about the method to use, but I'd like to expand on the explanation a bit.
When you pass selectors (aka method names) from Perl, they're passed as strings, and if the method the selector describes takes an argument, you need to remember to add the trailing colon to indicate that to the Objective-C runtime.
Also, because an NSTableView normally has a data source but not a target for its action methods, you'll probably need to call setTarget: as well as setDoubleAction:.
Here's an example snippet to get you started. As written, this would go in your controller class' constructor, and the doubleClick method would also be in the controller class.
Log in to post a comment.
Sign up for the SourceForge newsletter:
You seem to have CSS turned off.
Please don't fill out this field.