diff options
author | Bibiko <bibiko@eva.mpg.de> | 2010-12-01 12:41:11 +0000 |
---|---|---|
committer | Bibiko <bibiko@eva.mpg.de> | 2010-12-01 12:41:11 +0000 |
commit | 426b66613cd49497b4e8ad4246031c0e43b2ec27 (patch) | |
tree | 79578d36c6e4b0f977a4c781e83413358c4241bf /Source/SPBundleEditorController.m | |
parent | 019a1015546ab203eb366a71811d6c75b130fd40 (diff) | |
download | sequelpro-426b66613cd49497b4e8ad4246031c0e43b2ec27.tar.gz sequelpro-426b66613cd49497b4e8ad4246031c0e43b2ec27.tar.bz2 sequelpro-426b66613cd49497b4e8ad4246031c0e43b2ec27.zip |
• Bundle Editor : ESC while bundle file renaming aborts editing
• after closing HTML output window reset windowUUID to allow to come up with a new window for the same command from same caller instance
Diffstat (limited to 'Source/SPBundleEditorController.m')
-rw-r--r-- | Source/SPBundleEditorController.m | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/Source/SPBundleEditorController.m b/Source/SPBundleEditorController.m index 4f415416..823feae8 100644 --- a/Source/SPBundleEditorController.m +++ b/Source/SPBundleEditorController.m @@ -1138,6 +1138,23 @@ #pragma mark - #pragma mark TableView delegate +/** + * Traps enter and esc and edit/cancel without entering next row + */ +- (BOOL)control:(NSControl *)control textView:(NSTextView *)textView doCommandBySelector:(SEL)command +{ + if ( [[control window] methodForSelector:command] == [[control window] methodForSelector:@selector(_cancelKey:)] || + [textView methodForSelector:command] == [textView methodForSelector:@selector(complete:)] ) { + + //abort editing + [control abortEditing]; + [[NSApp mainWindow] makeFirstResponder:commandsOutlineView]; + return TRUE; + } else{ + return FALSE; + } +} + - (void)controlTextDidEndEditing:(NSNotification *)aNotification { |