aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorrowanbeentje <rowan@beent.je>2013-01-06 01:36:39 +0000
committerrowanbeentje <rowan@beent.je>2013-01-06 01:36:39 +0000
commitb659d41228422e9ed6c5e94bed879c2b2b57a115 (patch)
treed48996c7d07f09fda3dcca61f38a60f5ecc54d67
parenta3a738ea230ead792aa747e4a66ced6e8bea8562 (diff)
downloadsequelpro-b659d41228422e9ed6c5e94bed879c2b2b57a115.tar.gz
sequelpro-b659d41228422e9ed6c5e94bed879c2b2b57a115.tar.bz2
sequelpro-b659d41228422e9ed6c5e94bed879c2b2b57a115.zip
- Fix problems editing the connection name when editing has just begun, addressing Issue #1518
-rw-r--r--Source/SPConnectionControllerDelegate.m4
1 files changed, 2 insertions, 2 deletions
diff --git a/Source/SPConnectionControllerDelegate.m b/Source/SPConnectionControllerDelegate.m
index e986b271..a9fb8621 100644
--- a/Source/SPConnectionControllerDelegate.m
+++ b/Source/SPConnectionControllerDelegate.m
@@ -451,7 +451,7 @@ static NSString *SPQuickConnectImageWhite = @"quick-connect-icon-white.pdf";
[self _startEditingConnection];
- if (favoriteNameFieldWasAutogenerated) {
+ if (favoriteNameFieldWasAutogenerated && (field != standardNameField && field != socketNameField && field != sshNameField)) {
[self setName:[self _generateNameForConnection]];
}
}
@@ -478,7 +478,7 @@ static NSString *SPQuickConnectImageWhite = @"quick-connect-icon-white.pdf";
// Enable user@host update in reaction to other UI changes
favoriteNameFieldWasAutogenerated = YES;
- } else if (![[field stringValue] isEqualToString:[self name]]) {
+ } else if (![[field stringValue] isEqualToString:[self _generateNameForConnection]]) {
favoriteNameFieldWasAutogenerated = NO;
[self setName:favoriteName];
}