diff options
author | rowanbeentje <rowan@beent.je> | 2011-04-14 00:23:22 +0000 |
---|---|---|
committer | rowanbeentje <rowan@beent.je> | 2011-04-14 00:23:22 +0000 |
commit | ad7328e56541556d23f527303deddaefd4253ef2 (patch) | |
tree | 344dbe7ac1780cfa81952be0cdb34ef20ca7f7bd /Source/SPTableStructureDelegate.m | |
parent | 0ce916eb0583ec6b062786f91bee0133906671ce (diff) | |
download | sequelpro-ad7328e56541556d23f527303deddaefd4253ef2.tar.gz sequelpro-ad7328e56541556d23f527303deddaefd4253ef2.tar.bz2 sequelpro-ad7328e56541556d23f527303deddaefd4253ef2.zip |
Make some minor changes after reviewing r3271:
- Fix a few encoding issues
- Recode a few [NSApp keyWindow] uses back to [SPDatabaseDocument parentWindow] following discussion; possibly for later refactoring into use of an error method
Diffstat (limited to 'Source/SPTableStructureDelegate.m')
-rw-r--r-- | Source/SPTableStructureDelegate.m | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/Source/SPTableStructureDelegate.m b/Source/SPTableStructureDelegate.m index 9c8f341c..73496e94 100644 --- a/Source/SPTableStructureDelegate.m +++ b/Source/SPTableStructureDelegate.m @@ -129,7 +129,7 @@ [chooseKeyButton selectItemWithTag:SPPrimaryKeyMenuTag]; [NSApp beginSheet:keySheet - modalForWindow:[NSApp keyWindow] modalDelegate:self + modalForWindow:[tableDocumentInstance parentWindow] modalDelegate:self didEndSelector:@selector(sheetDidEnd:returnCode:contextInfo:) contextInfo:@"autoincrementindex" ]; } @@ -352,7 +352,7 @@ [mySQLConnection queryString:queryString]; if ([mySQLConnection queryErrored]) { - SPBeginAlertSheet(NSLocalizedString(@"Error moving field", @"error moving field message"), NSLocalizedString(@"OK", @"OK button"), nil, nil, [NSApp keyWindow], self, nil, nil, + SPBeginAlertSheet(NSLocalizedString(@"Error moving field", @"error moving field message"), NSLocalizedString(@"OK", @"OK button"), nil, nil, [tableDocumentInstance parentWindow], self, nil, nil, [NSString stringWithFormat:NSLocalizedString(@"An error occurred while trying to move the field.\n\nMySQL said: %@", @"error moving field informative message"), [mySQLConnection getLastErrorMessage]]); } else { @@ -475,7 +475,7 @@ [[control window] makeFirstResponder:control]; [self addRowToDB]; [tableSourceView selectRowIndexes:[NSIndexSet indexSetWithIndex:row] byExtendingSelection:NO]; - [[NSApp keyWindow] makeFirstResponder:tableSourceView]; + [[tableDocumentInstance parentWindow] makeFirstResponder:tableSourceView]; return YES; } |