diff options
author | Damiano Galassi <[email protected]> | 2017-02-22 15:05:21 +0100 |
---|---|---|
committer | Damiano Galassi <[email protected]> | 2017-02-22 15:05:21 +0100 |
commit | 7cf4263c54b0b671cce382854a600828656c0f04 (patch) | |
tree | 7f174fbc840ac12176d8aa69bb9173cf8e14adcc /macosx/HBController.m | |
parent | 380059d4d8cf245e3667a5c92159f7b294d682ac (diff) |
MacGui: preserve the output file name if auto naming is not enabled and the source is not a stream. Revert to the 0.10.x behaviour.
Diffstat (limited to 'macosx/HBController.m')
-rw-r--r-- | macosx/HBController.m | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/macosx/HBController.m b/macosx/HBController.m index 602401a2a..fa57e1141 100644 --- a/macosx/HBController.m +++ b/macosx/HBController.m @@ -708,7 +708,17 @@ HBJob *job = [[HBJob alloc] initWithTitle:title andPreset:self.currentPreset]; job.outputURL = self.currentDestination; - job.outputFileName = [HBUtilities defaultNameForJob:job]; + + // If the source is not a stream, and autonaming is disabled, + // keep the existing file name. + if (self.job.outputFileName.length == 0 || title.isStream || [[NSUserDefaults standardUserDefaults] boolForKey:@"DefaultAutoNaming"]) + { + job.outputFileName = [HBUtilities defaultNameForJob:job]; + } + else + { + job.outputFileName = self.job.outputFileName; + } return job; } |