aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Source/SPConnectionController.m7
-rw-r--r--Source/SPConnectionControllerDelegate.m2
2 files changed, 5 insertions, 4 deletions
diff --git a/Source/SPConnectionController.m b/Source/SPConnectionController.m
index aaff9687..4e8338aa 100644
--- a/Source/SPConnectionController.m
+++ b/Source/SPConnectionController.m
@@ -248,6 +248,9 @@
isConnecting = YES;
cancellingConnection = NO;
+ // Disable the favorites outline view to prevent further connections attempts
+ [favoritesTable setEnabled:NO];
+
[addToFavoritesButton setHidden:YES];
[addToFavoritesButton display];
[helpButton setHidden:YES];
@@ -387,6 +390,7 @@
if (newState == PROXY_STATE_IDLE) {
[tableDocument setTitlebarStatus:NSLocalizedString(@"SSH Disconnected", @"SSH disconnected titlebar marker")];
[self failConnectionWithTitle:NSLocalizedString(@"SSH connection failed!", @"SSH connection failed title") errorMessage:[theTunnel lastError] detail:[sshTunnel debugMessages]];
+ [self _restoreConnectionInterface];
} else if (newState == PROXY_STATE_CONNECTED) {
[tableDocument setTitlebarStatus:NSLocalizedString(@"SSH Connected", @"SSH connected titlebar marker")];
[self initiateMySQLConnection];
@@ -400,9 +404,6 @@
*/
- (void)initiateMySQLConnection
{
- // Disable the favorites table view to prevent further connections attempts
- [favoritesTable setEnabled:NO];
-
if (sshTunnel)
[progressIndicatorText setStringValue:NSLocalizedString(@"MySQL connecting...", @"MySQL connecting very short status message")];
else
diff --git a/Source/SPConnectionControllerDelegate.m b/Source/SPConnectionControllerDelegate.m
index a2653c5a..6bb0ee47 100644
--- a/Source/SPConnectionControllerDelegate.m
+++ b/Source/SPConnectionControllerDelegate.m
@@ -218,7 +218,7 @@
*/
- (BOOL)outlineView:(NSOutlineView *)outlineView shouldEditTableColumn:(NSTableColumn *)tableColumn item:(id)item
{
- [self initiateConnection:self];
+ if (!isConnecting) [self initiateConnection:self];
return NO;
}
@end