diff options
Diffstat (limited to 'Source')
-rw-r--r-- | Source/TablesList.h | 1 | ||||
-rw-r--r-- | Source/TablesList.m | 11 |
2 files changed, 6 insertions, 6 deletions
diff --git a/Source/TablesList.h b/Source/TablesList.h index 032f7f15..8a13e487 100644 --- a/Source/TablesList.h +++ b/Source/TablesList.h @@ -46,6 +46,7 @@ enum sp_table_types IBOutlet id tableDumpInstance; IBOutlet id tableDataInstance; IBOutlet id extendedTableInfoInstance; + IBOutlet id databaseDataInstance; IBOutlet id tableWindow; IBOutlet id copyTableSheet; diff --git a/Source/TablesList.m b/Source/TablesList.m index d07fe544..ae438dec 100644 --- a/Source/TablesList.m +++ b/Source/TablesList.m @@ -35,6 +35,7 @@ #import "SPStringAdditions.h" #import "SPArrayAdditions.h" #import "RegexKitLite.h" +#import "SPDatabaseData.h" @implementation TablesList @@ -209,17 +210,15 @@ // Populate the table type (engine) popup button [tableTypeButton removeAllItems]; - CMMCPResult *engines = [mySQLConnection queryString:@"SELECT engine FROM information_schema.engines"]; - - [engines dataSeek:0]; - + NSArray *engines = [databaseDataInstance getDatabaseStorageEngines]; + // Add default menu item [tableTypeButton addItemWithTitle:@"Default"]; [[tableTypeButton menu] addItem:[NSMenuItem separatorItem]]; - for (int i = 0; i < [engines numOfRows]; i++) + for (NSDictionary *engine in engines) { - [tableTypeButton addItemWithTitle:[[engines fetchRowAsArray] objectAtIndex:0]]; + [tableTypeButton addItemWithTitle:[engine objectForKey:@"Engine"]]; } [NSApp beginSheet:tableSheet |