aboutsummaryrefslogtreecommitdiffstats
path: root/Source/SPNarrowDownCompletion.m
diff options
context:
space:
mode:
authorMax <post@wickenrode.com>2015-01-04 21:15:43 +0100
committerMax <post@wickenrode.com>2015-01-04 21:15:43 +0100
commite201531daa71ee1a2e2a0f927c619947126c9d3d (patch)
tree9b43cecf579b4318ec9b8f04c970a40c3232ba15 /Source/SPNarrowDownCompletion.m
parent5b55d8c4d24b0c24a5dc74a49cfd70448146d582 (diff)
downloadsequelpro-e201531daa71ee1a2e2a0f927c619947126c9d3d.tar.gz
sequelpro-e201531daa71ee1a2e2a0f927c619947126c9d3d.tar.bz2
sequelpro-e201531daa71ee1a2e2a0f927c619947126c9d3d.zip
Addition to commit 2735e15b
Diffstat (limited to 'Source/SPNarrowDownCompletion.m')
-rw-r--r--Source/SPNarrowDownCompletion.m29
1 files changed, 12 insertions, 17 deletions
diff --git a/Source/SPNarrowDownCompletion.m b/Source/SPNarrowDownCompletion.m
index cb1ba20b..d5391644 100644
--- a/Source/SPNarrowDownCompletion.m
+++ b/Source/SPNarrowDownCompletion.m
@@ -159,18 +159,16 @@
[NSObject cancelPreviousPerformRequestsWithTarget:self];
if(stateTimer != nil) {
[stateTimer invalidate];
- [stateTimer release];
- stateTimer = nil;
+ SPClear(stateTimer);
}
- if (staticPrefix) [staticPrefix release];
- [mutablePrefix release];
- [textualInputCharacters release];
- [originalFilterString release];
- if(syncArrowImages) [syncArrowImages release];
- if(suggestions) [suggestions release];
-
- if (filtered) [filtered release];
- if (databaseStructureRetrieval) [databaseStructureRetrieval release];
+ SPClear(mutablePrefix);
+ SPClear(textualInputCharacters);
+ SPClear(originalFilterString);
+ if (staticPrefix) SPClear(staticPrefix);
+ if (syncArrowImages) SPClear(syncArrowImages);
+ if (suggestions) SPClear(suggestions);
+ if (filtered) SPClear(filtered);
+ if (databaseStructureRetrieval) SPClear(databaseStructureRetrieval);
[super dealloc];
}
@@ -181,8 +179,7 @@
// Invalidate the timer now to prevent retain cycles preventing deallocation
if (stateTimer != nil) {
[stateTimer invalidate];
- [stateTimer release];
- stateTimer = nil;
+ SPClear(stateTimer);
}
closeMe = YES;
@@ -204,8 +201,7 @@
isQueryingDatabaseStructure = NO;
if(stateTimer) {
[stateTimer invalidate];
- [stateTimer release];
- stateTimer = nil;
+ SPClear(stateTimer);
if(syncArrowImages) SPClear(syncArrowImages);
[self performSelectorOnMainThread:@selector(reInvokeCompletion) withObject:nil waitUntilDone:YES];
closeMe = YES;
@@ -222,8 +218,7 @@
{
if(stateTimer) {
[stateTimer invalidate];
- [stateTimer release];
- stateTimer = nil;
+ SPClear(stateTimer);
}
[theView setCompletionIsOpen:NO];
[self close];