Copy and Paste of rows in a NSTableView
Copy and Paste of rows in a NSTableView
- Subject: Copy and Paste of rows in a NSTableView
- From: Stéphane Sudre <email@hidden>
- Date: Mon, 11 Jun 2001 15:55:22 +0200
I must confess that I've looked in the documentation and in various
archives and examples and found no answer till now.
I have a NSTableView and want to be able to copy/paste data relating the
lines selected.
Since the Data owner is not the table view I suspect that there is a
delegate thing involved in this case. But I didn't find the delegate
method related to cut/copy/paste/Select All and other stuffs.
So maybe the delegate must implement the cut:(id) sender method himself.
Then comes the problem of sending this action to the delegate (which is
not in the same nib file as the Main Menu) and deciding whether this
action can be done or not according to the selection. NSMenuValidation I
guess.
But I need to make the link between cut/paste action and the Menu Item
and the delegate. I believe it has something to do with the First
Responder.
But it's still dark at thi spoint.