aboutsummaryrefslogtreecommitdiffstats
path: root/Source
diff options
context:
space:
mode:
authorrowanbeentje <rowan@beent.je>2009-12-01 22:41:05 +0000
committerrowanbeentje <rowan@beent.je>2009-12-01 22:41:05 +0000
commit8b2503aaed2a149c932697eb58d993aff25f3fdd (patch)
treeebc0714a0390ce63e27ab8e9914aef322d233105 /Source
parent044639f54e6acbe7c383c8d0ca5197c8eb7e19e9 (diff)
downloadsequelpro-8b2503aaed2a149c932697eb58d993aff25f3fdd.tar.gz
sequelpro-8b2503aaed2a149c932697eb58d993aff25f3fdd.tar.bz2
sequelpro-8b2503aaed2a149c932697eb58d993aff25f3fdd.zip
- Ensure the table length is updated before the end of the load to fix crashes in the old non-threaded code when the row count is reduced (performSelectorOnMainThread:waitUntilDone:NO was deferring updates until past table reload). This addresses Issue #487.
Diffstat (limited to 'Source')
-rw-r--r--Source/TableContent.m2
1 files changed, 2 insertions, 0 deletions
diff --git a/Source/TableContent.m b/Source/TableContent.m
index 06fc9dce..868b0ad1 100644
--- a/Source/TableContent.m
+++ b/Source/TableContent.m
@@ -702,6 +702,8 @@
pthread_mutex_unlock(&tableValuesLock);
}
+ // Ensure the table is aware of changes, especially for non-threaded loads
+ [tableContentView performSelectorOnMainThread:@selector(noteNumberOfRowsChanged) withObject:nil waitUntilDone:YES];
[tableContentView performSelectorOnMainThread:@selector(reloadData) withObject:nil waitUntilDone:NO];
// Clean up the autorelease pool and reset the progress indicator