Re: How to deselect a selected row?
Re: How to deselect a selected row?
- Subject: Re: How to deselect a selected row?
- From: Calum Robinson <email@hidden>
- Date: Wed, 9 Apr 2003 13:24:26 +0100
I think didClickTableColumn is only called when the header of the
column is clicked - and not the contents (but I may be mistaken).
Perhaps you could put an NSLog() in there to check it's being called.
It looks like you want to disable selection completely in your table,
so you should probably override tableView:shouldSelectRow: instead.
On Wednesday, April 9, 2003, at 01:16 pm, Suman Ganguly wrote:
Actually I don't want multiple row selection. I just want to select a
row by
one mouse click and deselect the same row by another mouse click. I
tried it
by the following delegate (Yes, I was using -[NSTableView
deselectRow:]),
but it did not work. Is anything wrong in the following code?
- (void) tableView:(NSTableView*)tableView
didClickTableColumn:(NSTableColumn *)tableColumn {
int index = [ tableView clickedRow ];
[tableView deselectRow: index];
}
Calum
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.