aboutsummaryrefslogtreecommitdiffstats
path: root/Source
diff options
context:
space:
mode:
Diffstat (limited to 'Source')
-rw-r--r--Source/SPTableContent.m12
1 files changed, 12 insertions, 0 deletions
diff --git a/Source/SPTableContent.m b/Source/SPTableContent.m
index 0d33c1ae..4e3ee245 100644
--- a/Source/SPTableContent.m
+++ b/Source/SPTableContent.m
@@ -81,6 +81,7 @@ static NSString *SPTableFilterSetDefaultOperator = @"SPTableFilterSetDefaultOper
@interface SPTableContent ()
- (BOOL)cancelRowEditing;
+- (void)documentWillClose:(NSNotification *)notification;
@end
@@ -292,6 +293,10 @@ static NSString *SPTableFilterSetDefaultOperator = @"SPTableFilterSetDefaultOper
selector:@selector(endDocumentTaskForTab:)
name:SPDocumentTaskEndNotification
object:tableDocumentInstance];
+ [[NSNotificationCenter defaultCenter] addObserver:self
+ selector:@selector(documentWillClose:)
+ name:SPDocumentWillCloseNotification
+ object:tableDocumentInstance];
}
#pragma mark -
@@ -4135,6 +4140,13 @@ static NSString *SPTableFilterSetDefaultOperator = @"SPTableFilterSetDefaultOper
tableRowsSelectable = YES;
}
+//this method is called right before the UI objects are deallocated
+- (void)documentWillClose:(NSNotification *)notification
+{
+ // if a result load is in progress we must stop the timer or it may try to call invalid IBOutlets
+ [self clearTableLoadTimer];
+}
+
#pragma mark -
#pragma mark KVO methods