summaryrefslogtreecommitdiffstats
path: root/macosx/HBVideoController.m
diff options
context:
space:
mode:
Diffstat (limited to 'macosx/HBVideoController.m')
-rw-r--r--macosx/HBVideoController.m4
1 files changed, 2 insertions, 2 deletions
diff --git a/macosx/HBVideoController.m b/macosx/HBVideoController.m
index e2d5d760d..5a22333ed 100644
--- a/macosx/HBVideoController.m
+++ b/macosx/HBVideoController.m
@@ -190,13 +190,13 @@ static void *HBVideoControllerContext = &HBVideoControllerContext;
granularity = [[NSUserDefaults standardUserDefaults]
floatForKey:@"x264CqSliderFractional"];
}
- [fVidQualitySlider setNumberOfTickMarks:((maxValue - minValue) *
+ [fVidQualitySlider setNumberOfTickMarks:(int)((maxValue - minValue) *
(1.0f / granularity)) + 1];
// Replace the slider transformer with a new one,
// configured with the new max/min/direction values.
[fVidQualitySlider unbind:@"value"];
- HBQualityTransformer *transformer = [[[HBQualityTransformer alloc] initWithReversedDirection:direction min:minValue max:maxValue] autorelease];
+ HBQualityTransformer *transformer = [[[HBQualityTransformer alloc] initWithReversedDirection:(direction != 0) min:minValue max:maxValue] autorelease];
[fVidQualitySlider bind:@"value" toObject:self withKeyPath:@"self.video.quality" options:@{NSValueTransformerBindingOption: transformer}];
}