aboutsummaryrefslogtreecommitdiffstats
path: root/Source
diff options
context:
space:
mode:
Diffstat (limited to 'Source')
-rw-r--r--Source/SPTableContent.m23
1 files changed, 12 insertions, 11 deletions
diff --git a/Source/SPTableContent.m b/Source/SPTableContent.m
index aeac9bc4..48871c11 100644
--- a/Source/SPTableContent.m
+++ b/Source/SPTableContent.m
@@ -1323,20 +1323,21 @@ static NSString *SPTableFilterSetDefaultOperator = @"SPTableFilterSetDefaultOper
{
NSAutoreleasePool *reloadPool = [[NSAutoreleasePool alloc] init];
- // Check whether a save of the current row is required.
- if (![[self onMainThread] saveRowOnDeselect]) return;
+ // Check whether a save of the current row is required, abort if pending changes couldn't be saved.
+ if ([[self onMainThread] saveRowOnDeselect]) {
- // Save view details to restore safely if possible (except viewport, which will be
- // preserved automatically, and can then be scrolled as the table loads)
- [self storeCurrentDetailsForRestoration];
- [self setViewportToRestore:NSZeroRect];
+ // Save view details to restore safely if possible (except viewport, which will be
+ // preserved automatically, and can then be scrolled as the table loads)
+ [self storeCurrentDetailsForRestoration];
+ [self setViewportToRestore:NSZeroRect];
- // Clear the table data column cache and status (including counts)
- [tableDataInstance resetColumnData];
- [tableDataInstance resetStatusData];
+ // Clear the table data column cache and status (including counts)
+ [tableDataInstance resetColumnData];
+ [tableDataInstance resetStatusData];
- // Load the table's data
- [self loadTable:[tablesListInstance tableName]];
+ // Load the table's data
+ [self loadTable:[tablesListInstance tableName]];
+ }
[tableDocumentInstance endTask];