aboutsummaryrefslogtreecommitdiffstats
path: root/Source/SPTableContent.h
diff options
context:
space:
mode:
authorrowanbeentje <rowan@beent.je>2010-08-12 01:15:44 +0000
committerrowanbeentje <rowan@beent.je>2010-08-12 01:15:44 +0000
commite5aa4302f8655a08d7fa7542893db009a6920689 (patch)
tree72a12fcf45eaa76e72a2350576a65a0ace6af08e /Source/SPTableContent.h
parent8b1962153814426bfb7e4ab38056ffa955d7c3f0 (diff)
downloadsequelpro-e5aa4302f8655a08d7fa7542893db009a6920689.tar.gz
sequelpro-e5aa4302f8655a08d7fa7542893db009a6920689.tar.bz2
sequelpro-e5aa4302f8655a08d7fa7542893db009a6920689.zip
Implement column autosizing for the Content View:
- Add automatic column sizing (for columns without saved widths) as part of the value loading process - Rework table updates to be timer based, for time-based and more regular updates. This improves speed and allows tables to update more consistently. This results in overall smoother table loads, faster table loads, and autosizing columns. This partially implements Issues #271 and #272. Column autosizing will likely be tweaked, and this will all also be extended to Custom Query views in a future patch.
Diffstat (limited to 'Source/SPTableContent.h')
-rw-r--r--Source/SPTableContent.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/Source/SPTableContent.h b/Source/SPTableContent.h
index 7b87bc32..1899d6a6 100644
--- a/Source/SPTableContent.h
+++ b/Source/SPTableContent.h
@@ -99,6 +99,9 @@
NSString *filterFieldToRestore, *filterComparisonToRestore, *filterValueToRestore, *firstBetweenValueToRestore, *secondBetweenValueToRestore;
NSInteger paginationViewHeight;
+
+ NSTimer *tableLoadTimer;
+ NSUInteger tableLoadInterfaceUpdateInterval, tableLoadTimerTicksSinceLastUpdate, tableLoadLastRowCount;
}
// Table loading methods and information
@@ -107,6 +110,9 @@
- (void) loadTableValues;
- (NSString *) tableFilterString;
- (void) updateCountText;
+- (void) initTableLoadTimer;
+- (void) clearTableLoadTimer;
+- (void) tableLoadUpdate:(NSTimer *)theTimer;
// Table interface actions
- (IBAction) reloadTable:(id)sender;
@@ -148,6 +154,7 @@
- (NSString *)fieldListForQuery;
- (void)updateNumberOfRows;
- (NSInteger)fetchNumberOfRows;
+- (void)autosizeColumns;
- (BOOL)saveRowOnDeselect;
- (void)sortTableTaskWithColumn:(NSTableColumn *)tableColumn;