diff options
Diffstat (limited to 'Source')
-rw-r--r-- | Source/SPConnectionController.h | 1 | ||||
-rw-r--r-- | Source/SPConnectionController.m | 17 | ||||
-rw-r--r-- | Source/SPPreferenceController.h | 1 | ||||
-rw-r--r-- | Source/SPPreferenceController.m | 18 |
4 files changed, 23 insertions, 14 deletions
diff --git a/Source/SPConnectionController.h b/Source/SPConnectionController.h index 67bdb77b..0a1f8cce 100644 --- a/Source/SPConnectionController.h +++ b/Source/SPConnectionController.h @@ -104,6 +104,7 @@ IBOutlet NSView *standardConnectionFormContainer; IBOutlet NSView *socketConnectionFormContainer; IBOutlet NSView *sshConnectionFormContainer; + IBOutlet NSView *sshKeyLocationHelp; IBOutlet NSTextField *standardSQLHostField; IBOutlet NSTextField *sshSQLHostField; diff --git a/Source/SPConnectionController.m b/Source/SPConnectionController.m index 7937ef99..a0ee7786 100644 --- a/Source/SPConnectionController.m +++ b/Source/SPConnectionController.m @@ -496,13 +496,16 @@ filePath = [sshKeyLocation lastPathComponent]; directoryPath = [sshKeyLocation stringByDeletingLastPathComponent]; } - [[NSOpenPanel openPanel] beginSheetForDirectory:directoryPath - file:filePath - types:[NSArray arrayWithObjects:@"pem", @"", nil] - modalForWindow:[tableDocument parentWindow] - modalDelegate:self - didEndSelector:@selector(chooseSSHKeySheetDidEnd:returnCode:contextInfo:) - contextInfo:nil]; + + NSOpenPanel *openPanel = [NSOpenPanel openPanel]; + [openPanel setAccessoryView:sshKeyLocationHelp]; + [openPanel beginSheetForDirectory:directoryPath + file:filePath + types:[NSArray arrayWithObjects:@"pem", @"", nil] + modalForWindow:[tableDocument parentWindow] + modalDelegate:self + didEndSelector:@selector(chooseSSHKeySheetDidEnd:returnCode:contextInfo:) + contextInfo:nil]; } /** diff --git a/Source/SPPreferenceController.h b/Source/SPPreferenceController.h index 1683db65..7d8e0375 100644 --- a/Source/SPPreferenceController.h +++ b/Source/SPPreferenceController.h @@ -58,6 +58,7 @@ IBOutlet NSTextField *favoriteUserTextFieldSSH; IBOutlet NSTextField *favoriteHostTextFieldSSH; IBOutlet NSMenuItem *favoritesSortByMenuItem; + IBOutlet NSView *sshKeyLocationHelp; IBOutlet NSWindow *enterNameWindow; IBOutlet NSTextField *enterNameLabel; diff --git a/Source/SPPreferenceController.m b/Source/SPPreferenceController.m index 42503649..c1f3877a 100644 --- a/Source/SPPreferenceController.m +++ b/Source/SPPreferenceController.m @@ -704,13 +704,17 @@ filePath = [[favoritesController valueForKeyPath:@"selection.sshKeyLocation"] lastPathComponent]; directoryPath = [[favoritesController valueForKeyPath:@"selection.sshKeyLocation"] stringByDeletingLastPathComponent]; } - [[NSOpenPanel openPanel] beginSheetForDirectory:directoryPath - file:filePath - types:[NSArray arrayWithObjects:@"pem", @"", nil] - modalForWindow:preferencesWindow - modalDelegate:self - didEndSelector:@selector(chooseSSHKeySheetDidEnd:returnCode:contextInfo:) - contextInfo:nil]; + + + NSOpenPanel *openPanel = [NSOpenPanel openPanel]; + [openPanel setAccessoryView:sshKeyLocationHelp]; + [openPanel beginSheetForDirectory:directoryPath + file:filePath + types:[NSArray arrayWithObjects:@"pem", @"", nil] + modalForWindow:preferencesWindow + modalDelegate:self + didEndSelector:@selector(chooseSSHKeySheetDidEnd:returnCode:contextInfo:) + contextInfo:nil]; } /** |