aboutsummaryrefslogtreecommitdiffstats
path: root/Source/TablesList.m
diff options
context:
space:
mode:
authorrowanbeentje <rowan@beent.je>2009-11-10 00:22:43 +0000
committerrowanbeentje <rowan@beent.je>2009-11-10 00:22:43 +0000
commit0ce7f983fad694c57aff9217666435685dea5e05 (patch)
tree281d98e3572d4127b1150703cc03c1fdc393f1a6 /Source/TablesList.m
parentf04ce0c7a9266238d3391f03c9193ca92071812e (diff)
downloadsequelpro-0ce7f983fad694c57aff9217666435685dea5e05.tar.gz
sequelpro-0ce7f983fad694c57aff9217666435685dea5e05.tar.bz2
sequelpro-0ce7f983fad694c57aff9217666435685dea5e05.zip
- Fix an issue when switching databases - allow the table selection to be cleared/reset as necessary
- Move the task progress layer to a child window, which can then be faded in - smooths the visual appearance and fixes drawing artifacts
Diffstat (limited to 'Source/TablesList.m')
-rw-r--r--Source/TablesList.m5
1 files changed, 5 insertions, 0 deletions
diff --git a/Source/TablesList.m b/Source/TablesList.m
index fbbd412c..5bba8be5 100644
--- a/Source/TablesList.m
+++ b/Source/TablesList.m
@@ -63,6 +63,7 @@
int i;
NSString *previousSelectedTable = nil;
NSInteger selectedRowIndex;
+ BOOL previousTableListIsSelectable = tableListIsSelectable;
selectedRowIndex = [tablesListView selectedRow];
@@ -76,7 +77,9 @@
}
tableListContainsViews = NO;
+ tableListIsSelectable = YES;
[tablesListView deselectAll:self];
+ tableListIsSelectable = previousTableListIsSelectable;
[tables removeAllObjects];
[tableTypes removeAllObjects];
@@ -216,7 +219,9 @@
// if the previous selected table still exists, select it
if( previousSelectedTable != nil && [tables indexOfObject:previousSelectedTable] < [tables count]) {
int itemToReselect = [tables indexOfObject:previousSelectedTable];
+ tableListIsSelectable = YES;
[tablesListView selectRowIndexes:[NSIndexSet indexSetWithIndex:itemToReselect] byExtendingSelection:NO];
+ tableListIsSelectable = previousTableListIsSelectable;
if (selectedTableName) [selectedTableName release];
selectedTableName = [[NSString alloc] initWithString:[tables objectAtIndex:itemToReselect]];
selectedTableType = [[tableTypes objectAtIndex:itemToReselect] intValue];