aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Source/SPAppController.m4
-rw-r--r--Source/SPConstants.h1
-rw-r--r--Source/SPConstants.m1
3 files changed, 4 insertions, 2 deletions
diff --git a/Source/SPAppController.m b/Source/SPAppController.m
index 3b8cde01..23d410e3 100644
--- a/Source/SPAppController.m
+++ b/Source/SPAppController.m
@@ -397,7 +397,7 @@
// Manually open a new document, setting SPAppController as sender to trigger autoconnection
if (firstTableDocument = [[NSDocumentController sharedDocumentController] makeUntitledDocumentOfType:@"SequelPro connection" error:nil]) {
- if ([[NSUserDefaults standardUserDefaults] boolForKey:@"AutoConnectToDefault"]) {
+ if ([[NSUserDefaults standardUserDefaults] boolForKey:SPAutoConnectToDefault]) {
[firstTableDocument setShouldAutomaticallyConnect:YES];
}
[[NSDocumentController sharedDocumentController] addDocument:firstTableDocument];
@@ -553,7 +553,7 @@
/* Support for "make new document"
*/
- (void)insertInOrderedDocuments:(TableDocument *)doc {
- if ([[NSUserDefaults standardUserDefaults] boolForKey:@"AutoConnectToDefault"])
+ if ([[NSUserDefaults standardUserDefaults] boolForKey:SPAutoConnectToDefault])
[doc setShouldAutomaticallyConnect:YES];
[[NSDocumentController sharedDocumentController] addDocument:doc];
[doc makeWindowControllers];
diff --git a/Source/SPConstants.h b/Source/SPConstants.h
index 8ab19b02..9e257894 100644
--- a/Source/SPConstants.h
+++ b/Source/SPConstants.h
@@ -61,6 +61,7 @@ extern NSString *SPConnectionTimeoutValue;
extern NSString *SPUseKeepAlive;
extern NSString *SPKeepAliveInterval;
extern NSString *SPEditInSheetEnabled;
+extern NSString *SPAutoConnectToDefault;
extern NSString *SPQueryFavoriteReplacesContent;
extern NSString *SPQueryHistoryReplacesContent;
extern NSString *SPCustomQueryEditorFont;
diff --git a/Source/SPConstants.m b/Source/SPConstants.m
index 50e9496f..b2a88ee1 100644
--- a/Source/SPConstants.m
+++ b/Source/SPConstants.m
@@ -44,6 +44,7 @@ NSString *SPConnectionTimeoutValue = @"ConnectionTimeoutValue";
NSString *SPUseKeepAlive = @"UseKeepAlive";
NSString *SPKeepAliveInterval = @"KeepAliveInterval";
NSString *SPEditInSheetEnabled = @"EditInSheetEnabled";
+NSString *SPAutoConnectToDefault = @"AutoConnectToDefault";
NSString *SPQueryFavoriteReplacesContent = @"QueryFavoriteReplacesContent";
NSString *SPQueryHistoryReplacesContent = @"QueryHistoryReplacesContent";
NSString *SPCustomQueryEditorFont = @"CustomQueryEditorFont";