aboutsummaryrefslogtreecommitdiffstats
path: root/Source/TableDocument.h
diff options
context:
space:
mode:
Diffstat (limited to 'Source/TableDocument.h')
-rw-r--r--Source/TableDocument.h38
1 files changed, 18 insertions, 20 deletions
diff --git a/Source/TableDocument.h b/Source/TableDocument.h
index 8272cd62..6b3acaef 100644
--- a/Source/TableDocument.h
+++ b/Source/TableDocument.h
@@ -26,10 +26,10 @@
// More info at <http://code.google.com/p/sequel-pro/>
#import <Cocoa/Cocoa.h>
-#import <MCPKit_bundled/MCPKit_bundled.h>
+#import <MCPKit/MCPKit.h>
#import <WebKit/WebKit.h>
-@class CMMCPConnection, CMMCPResult, SPConnectionController;
+@class SPConnectionController;
/**
* The TableDocument class controls the primary database view window.
@@ -79,10 +79,11 @@
IBOutlet id syntaxView;
IBOutlet id syntaxViewContent;
IBOutlet NSWindow *createTableSyntaxWindow;
+ IBOutlet NSWindow *connectionErrorDialog;
SPConnectionController *connectionController;
- CMMCPConnection *mySQLConnection;
+ MCPConnection *mySQLConnection;
NSArray *variables;
NSString *selectedDatabase;
@@ -95,6 +96,7 @@
BOOL _encodingViaLatin1;
BOOL _shouldOpenConnectionAutomatically;
BOOL _isConnected;
+ BOOL _mainNibLoaded;
NSToolbar *mainToolbar;
NSToolbarItem *chooseDatabaseToolbarItem;
@@ -107,11 +109,11 @@
- (NSString *)getHTMLforPrint;
// Connection callback and methods
-- (void) setConnection:(CMMCPConnection *)theConnection;
+- (void) setConnection:(MCPConnection *)theConnection;
- (void)setShouldAutomaticallyConnect:(BOOL)shouldAutomaticallyConnect;
- (BOOL)shouldAutomaticallyConnect;
-//database methods
+// Database methods
- (IBAction)setDatabases:(id)sender;
- (IBAction)chooseDatabase:(id)sender;
- (IBAction)addDatabase:(id)sender;
@@ -121,18 +123,18 @@
- (IBAction)saveServerVariables:(id)sender;
- (NSArray *)allDatabaseNames;
-//encoding methods
+// Encoding methods
- (void)setConnectionEncoding:(NSString *)mysqlEncoding reloadingViews:(BOOL)reloadViews;
- (NSString *)databaseEncoding;
- (NSString *)connectionEncoding;
-- (BOOL)connectionEncodingViaLatin1;
+- (BOOL)connectionEncodingViaLatin1:(id)connection;
- (IBAction)chooseEncoding:(id)sender;
- (BOOL)supportsEncoding;
- (void)updateEncodingMenuWithSelectedEncoding:(NSString *)encoding;
- (NSString *)encodingNameFromMySQLEncoding:(NSString *)mysqlEncoding;
- (NSString *)mysqlEncodingFromDisplayEncoding:(NSString *)encodingName;
-//table methods
+// Table methods
- (IBAction)showCreateTableSyntax:(id)sender;
- (IBAction)copyCreateTableSyntax:(id)sender;
- (NSArray *)columnNames;
@@ -143,8 +145,10 @@
- (IBAction)flushTable:(id)sender;
- (IBAction)checksumTable:(id)sender;
-//other methods
+// Other methods
- (NSString *)host;
+- (IBAction)closeSheet:(id)sender;
+- (IBAction)closeErrorConnectionSheet:(id)sender;
- (void)doPerformQueryService:(NSString *)query;
- (void)flushPrivileges:(id)sender;
- (void)showVariables:(id)sender;
@@ -152,19 +156,19 @@
- (NSWindow *)getCreateTableSyntaxWindow;
- (void) refreshCurrentDatabase;
-//getter methods
+// Getter methods
- (NSString *)name;
- (NSString *)database;
- (NSString *)table;
- (NSString *)mySQLVersion;
- (NSString *)user;
-//notification center methods
+// Notification center methods
- (void)willPerformQuery:(NSNotification *)notification;
- (void)hasPerformedQuery:(NSNotification *)notification;
- (void)applicationWillTerminate:(NSNotification *)notification;
-//menu methods
+// Menu methods
- (BOOL)validateMenuItem:(NSMenuItem *)anItem;
- (IBAction)import:(id)sender;
- (IBAction)export:(id)sender;
@@ -177,12 +181,12 @@
- (IBAction)viewRelations:(id)sender;
- (IBAction)addConnectionToFavorites:(id)sender;
-// titlebar methods
+// Titlebar methods
- (void)setStatusIconToImageWithName:(NSString *)imagePath;
- (void)setTitlebarStatus:(NSString *)status;
- (void)clearStatusIcon;
-//toolbar methods
+// Toolbar methods
- (void)setupToolbar;
- (NSToolbarItem *)toolbar:(NSToolbar *)toolbar itemForItemIdentifier:(NSString *)itemIdentifier willBeInsertedIntoToolbar:(BOOL)flag;
- (NSArray *)toolbarAllowedItemIdentifiers:(NSToolbar*)toolbar;
@@ -190,10 +194,4 @@
- (BOOL)validateToolbarItem:(NSToolbarItem *)toolbarItem;
- (void)updateChooseDatabaseToolbarItemWidth;
-//SMySQL delegate methods
-- (void)willQueryString:(NSString *)query;
-- (void)queryGaveError:(NSString *)error;
-
-- (IBAction)closeSheet:(id)sender;
-
@end