Permalink
Browse files

Fix objc weak errors by removing an unused delegate (#3062)

This code still seems wrong, though: -tableView:objectValueForTableColumn:row: is not the appropriate place to return cell objects
  • Loading branch information...
dmoagx committed May 30, 2018
1 parent f517fd3 commit 86aaa250e53fe6f631447351b9ec03741529cf98
Showing with 5 additions and 3 deletions.
  1. +1 −1 Source/SPNarrowDownCompletion.h
  2. +4 −2 Source/SPNarrowDownCompletion.m
@@ -32,7 +32,7 @@
@class SPDatabaseStructure;
@interface SPNarrowDownCompletion : NSWindow <NSTableViewDelegate, NSTableViewDataSource, NSTokenFieldCellDelegate>
@interface SPNarrowDownCompletion : NSWindow <NSTableViewDelegate, NSTableViewDataSource>
{
NSArray* suggestions;
NSMutableString* mutablePrefix;
@@ -163,6 +163,9 @@ - (void)dealloc
SPClear(mutablePrefix);
SPClear(textualInputCharacters);
SPClear(originalFilterString);
[theTableView setDataSource:nil];
[theTableView setDelegate:nil];
SPClear(theTableView);
if (staticPrefix) SPClear(staticPrefix);
if (syncArrowImages) SPClear(syncArrowImages);
if (suggestions) SPClear(suggestions);
@@ -353,7 +356,7 @@ - (void)setupInterface
[[scrollView verticalScroller] setControlSize:NSSmallControlSize];
[[scrollView horizontalScroller] setControlSize:NSSmallControlSize];
theTableView = [[[NSTableView alloc] initWithFrame:NSZeroRect] autorelease];
theTableView = [[NSTableView alloc] initWithFrame:NSZeroRect];
[theTableView setFocusRingType:NSFocusRingTypeNone];
[theTableView setAllowsEmptySelection:YES];
[theTableView setHeaderView:nil];
@@ -557,7 +560,6 @@ - (id)tableView:(NSTableView *)aTableView objectValueForTableColumn:(NSTableColu
[b setEditable:NO];
[b setAlignment:NSRightTextAlignment];
[b setFont:[NSFont systemFontOfSize:11]];
[b setDelegate:self];
return b;
}

0 comments on commit 86aaa25

Please sign in to comment.