summaryrefslogtreecommitdiffstats
path: root/macosx/HBAddPresetController.m
diff options
context:
space:
mode:
authorDamiano Galassi <[email protected]>2016-12-28 08:35:18 +0100
committerDamiano Galassi <[email protected]>2016-12-28 08:35:18 +0100
commite2cc12cf1dfa9ae3d98661a9ead330f496da3f2f (patch)
tree0e6d41f6fda1ff7f11e8af47c009b60b3810f9f5 /macosx/HBAddPresetController.m
parentd027d48da3b6305492741229bcd0e5cd9af29d60 (diff)
MacGui: set PictureWidth and PictureHeight when creating presets with the "Source Maximum" picture option. Fixes #455
Diffstat (limited to 'macosx/HBAddPresetController.m')
-rw-r--r--macosx/HBAddPresetController.m16
1 files changed, 12 insertions, 4 deletions
diff --git a/macosx/HBAddPresetController.m b/macosx/HBAddPresetController.m
index 9c82e4087..3cdce5cb0 100644
--- a/macosx/HBAddPresetController.m
+++ b/macosx/HBAddPresetController.m
@@ -154,12 +154,20 @@ typedef NS_ENUM(NSUInteger, HBAddPresetControllerMode) {
newPreset.name = self.name.stringValue;
newPreset.presetDescription = self.desc.stringValue;
- // Get the picture size
- newPreset[@"PictureWidth"] = @(self.picWidth.integerValue);
- newPreset[@"PictureHeight"] = @(self.picHeight.integerValue);
+ if (self.picSettingsPopUp.selectedTag == HBAddPresetControllerModeSourceMaximum)
+ {
+ newPreset[@"PictureWidth"] = @0;
+ newPreset[@"PictureHeight"] = @0;
+ }
+ else
+ {
+ // Get the user set picture size
+ newPreset[@"PictureWidth"] = @(self.picWidth.integerValue);
+ newPreset[@"PictureHeight"] = @(self.picHeight.integerValue);
+ }
//Get the whether or not to apply pic Size and Cropping (includes Anamorphic)
- newPreset[@"UsesPictureSettings"] = @(self.picSettingsPopUp.selectedItem.tag);
+ newPreset[@"UsesPictureSettings"] = @(self.picSettingsPopUp.selectedTag);
// Always use Picture Filter settings for the preset
newPreset[@"UsesPictureFilters"] = @YES;