aboutsummaryrefslogtreecommitdiffstats
path: root/Source
diff options
context:
space:
mode:
authorstuconnolly <stuart02@gmail.com>2010-09-05 20:02:00 +0000
committerstuconnolly <stuart02@gmail.com>2010-09-05 20:02:00 +0000
commit46344761d22504556f7fdf6321f706e33f85804f (patch)
tree3448c6ea9cecd0581bf7f4263c58ae1711599c02 /Source
parent7476468dd0b38d6cca82c85f244d16edaa81a520 (diff)
downloadsequelpro-46344761d22504556f7fdf6321f706e33f85804f.tar.gz
sequelpro-46344761d22504556f7fdf6321f706e33f85804f.tar.bz2
sequelpro-46344761d22504556f7fdf6321f706e33f85804f.zip
Minor enhancements to the CSV import dialogs new table info sheet (i.e. table encoding and type):
- Make the sheet non-resizable, thus removing the visible resize triangle. - Add a cancel button so the user can discard their selection. - Only save the user's selection when they select 'OK'.
Diffstat (limited to 'Source')
-rw-r--r--Source/SPFieldMapperController.m8
1 files changed, 6 insertions, 2 deletions
diff --git a/Source/SPFieldMapperController.m b/Source/SPFieldMapperController.m
index c77435cc..2b262be6 100644
--- a/Source/SPFieldMapperController.m
+++ b/Source/SPFieldMapperController.m
@@ -367,8 +367,12 @@
- (IBAction)closeInfoSheet:(id)sender
{
- [prefs setObject:[newTableInfoEnginePopup titleOfSelectedItem] forKey:SPLastImportIntoNewTableType];
- [prefs setObject:[newTableInfoEncodingPopup titleOfSelectedItem] forKey:SPLastImportIntoNewTableEncoding];
+ // Only save selection if the user selected 'OK'
+ if ([sender tag]) {
+ [prefs setObject:[newTableInfoEnginePopup titleOfSelectedItem] forKey:SPLastImportIntoNewTableType];
+ [prefs setObject:[newTableInfoEncodingPopup titleOfSelectedItem] forKey:SPLastImportIntoNewTableEncoding];
+ }
+
[NSApp endSheet:[sender window] returnCode:[sender tag]];
[[sender window] orderOut:self];
}