From 0dff71796759307023398775fde082e3bdd41d31 Mon Sep 17 00:00:00 2001 From: stuconnolly Date: Sun, 25 Jul 2010 11:32:17 +0000 Subject: During a CSV export if the user selects the tab as the separator update the extension to be .tsv --- Source/SPExportController.m | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) (limited to 'Source/SPExportController.m') diff --git a/Source/SPExportController.m b/Source/SPExportController.m index bb16d36f..b7d26fef 100644 --- a/Source/SPExportController.m +++ b/Source/SPExportController.m @@ -119,6 +119,12 @@ // If found the set the default path to the user's desktop, otherwise use their home directory [exportPathField setStringValue:([paths count] > 0) ? [paths objectAtIndex:0] : NSHomeDirectory()]; + + // Register to receive notifications of a change in selection of the CSV field separator + /*[[NSNotificationCenter defaultCenter] addObserver:self + selector:@selector(comboBoxSelectionDidChange:) + name:NSComboBoxSelectionDidChangeNotification + object:nil];*/ } #pragma mark - @@ -628,6 +634,16 @@ [self switchTab:self]; } +#pragma mark - +#pragma mark Combo box delegate methods + +- (void)comboBoxSelectionDidChange:(NSNotification *)notification +{ + if ([notification object] == exportCSVFieldsTerminatedField) { + [self updateDisplayedExportFilename]; + } +} + #pragma mark - #pragma mark Other -- cgit v1.2.3