aboutsummaryrefslogtreecommitdiffstats
path: root/TablesList.m
diff options
context:
space:
mode:
authoravenjamin <avenjamin@gmail.com>2008-12-05 16:22:43 +0000
committeravenjamin <avenjamin@gmail.com>2008-12-05 16:22:43 +0000
commitb0699390ce20fa73ddbb704b4532a10716ae9cab (patch)
treebca174d73fdb632a6ca84180198a535475482f03 /TablesList.m
parent4e7cc2be76b5a38dd6d1ef3512abf080f1b50e73 (diff)
downloadsequelpro-b0699390ce20fa73ddbb704b4532a10716ae9cab.tar.gz
sequelpro-b0699390ce20fa73ddbb704b4532a10716ae9cab.tar.bz2
sequelpro-b0699390ce20fa73ddbb704b4532a10716ae9cab.zip
TableDump
--- Field mapping when importing CSV file now makes more sense. You can import data into multiple columns in the table. Known Issue: changing table while field mapping doesn't work. Select the table first before importing TableContent --- Partially solves issue where label at bottom "x of y rows selected" wasn't being updated TablesList --- Moved table delegate methods under correct pragma mark
Diffstat (limited to 'TablesList.m')
-rw-r--r--TablesList.m76
1 files changed, 40 insertions, 36 deletions
diff --git a/TablesList.m b/TablesList.m
index a5ab02e5..454b6dd8 100644
--- a/TablesList.m
+++ b/TablesList.m
@@ -585,43 +585,7 @@ loads a table in content or source view (if tab selected)
}
}
-#pragma mark TabView delegate methods
-/*
-loads structure or source if tab selected the first time
-*/
-- (void)tabView:(NSTabView *)aTabView didSelectTabViewItem:(NSTabViewItem *)tabViewItem
-{
- if ( [tablesListView numberOfSelectedRows] == 1 ) {
-
- if ( ([tabView indexOfTabViewItem:[tabView selectedTabViewItem]] == 0) && !structureLoaded ) {
-
- [tableSourceInstance loadTable:[tables objectAtIndex:[tablesListView selectedRow]]];
- structureLoaded = YES;
- }
-
- if ( ([tabView indexOfTabViewItem:[tabView selectedTabViewItem]] == 1) && !contentLoaded ) {
-
- if ( !structureLoaded ) {
- [tableSourceInstance loadTable:[tables objectAtIndex:[tablesListView selectedRow]]];
- structureLoaded = YES;
- }
-
- [tableContentInstance loadTable:[tables objectAtIndex:[tablesListView selectedRow]]];
- contentLoaded = YES;
- }
-
- if ( ([tabView indexOfTabViewItem:[tabView selectedTabViewItem]] == 3) && !statusLoaded ) {
- [tableStatusInstance loadTable:[tables objectAtIndex:[tablesListView selectedRow]]];
- statusLoaded = YES;
- }
- }
-/*
- if ( [tabView indexOfTabViewItem:[tabView selectedTabViewItem]] == 3 ) {
- [tableDumpInstance reloadTables:self];
- }
-*/
-}
- (BOOL)tableView:(NSTableView *)aTableView shouldSelectRow:(int)rowIndex
{
@@ -665,6 +629,46 @@ loads structure or source if tab selected the first time
}
}
+#pragma mark -
+#pragma mark TabView delegate methods
+
+/*
+loads structure or source if tab selected the first time
+*/
+- (void)tabView:(NSTabView *)aTabView didSelectTabViewItem:(NSTabViewItem *)tabViewItem
+{
+ if ( [tablesListView numberOfSelectedRows] == 1 ) {
+
+ if ( ([tabView indexOfTabViewItem:[tabView selectedTabViewItem]] == 0) && !structureLoaded ) {
+
+ [tableSourceInstance loadTable:[tables objectAtIndex:[tablesListView selectedRow]]];
+ structureLoaded = YES;
+ }
+
+ if ( ([tabView indexOfTabViewItem:[tabView selectedTabViewItem]] == 1) && !contentLoaded ) {
+
+ if ( !structureLoaded ) {
+ [tableSourceInstance loadTable:[tables objectAtIndex:[tablesListView selectedRow]]];
+ structureLoaded = YES;
+ }
+
+ [tableContentInstance loadTable:[tables objectAtIndex:[tablesListView selectedRow]]];
+ contentLoaded = YES;
+ }
+
+ if ( ([tabView indexOfTabViewItem:[tabView selectedTabViewItem]] == 3) && !statusLoaded ) {
+ [tableStatusInstance loadTable:[tables objectAtIndex:[tablesListView selectedRow]]];
+ statusLoaded = YES;
+ }
+ }
+/*
+ if ( [tabView indexOfTabViewItem:[tabView selectedTabViewItem]] == 3 ) {
+ [tableDumpInstance reloadTables:self];
+ }
+*/
+}
+
+#pragma mark -
//last but not least
- (id)init
{