diff options
Diffstat (limited to 'redo/table_darwin.m')
| -rw-r--r-- | redo/table_darwin.m | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/redo/table_darwin.m b/redo/table_darwin.m index 5fdac83..a8c85be 100644 --- a/redo/table_darwin.m +++ b/redo/table_darwin.m @@ -17,7 +17,7 @@ @implementation goTableColumn @end -@interface goTableDataSource : NSObject <NSTableViewDataSource> { +@interface goTableDataSource : NSObject <NSTableViewDataSource, NSTableViewDelegate> { @public void *gotable; } @@ -63,6 +63,11 @@ goTableDataSource_toggled(self->gotable, (intptr_t) row, colnum, [value boolValue]); } +- (void)tableViewSelectionDidChange:(NSNotification *)note +{ + tableSelectionChanged(self->gotable); +} + @end id newTable(void) @@ -134,6 +139,7 @@ void tableUpdate(id t) [toNSTableView(t) reloadData]; } +// also sets the delegate void tableMakeDataSource(id table, void *gotable) { goTableDataSource *model; @@ -141,6 +147,7 @@ void tableMakeDataSource(id table, void *gotable) model = [goTableDataSource new]; model->gotable = gotable; [toNSTableView(table) setDataSource:model]; + [toNSTableView(table) setDelegate:model]; } // -[NSTableView sizeToFit] does not actually size to fit |
