Commit 8f6a0158 authored by Rémi Denis-Courmont's avatar Rémi Denis-Courmont

Qt4: clean volume step computation

parent 25040764
...@@ -439,7 +439,8 @@ SoundSlider::SoundSlider( QWidget *_parent, int _i_step, ...@@ -439,7 +439,8 @@ SoundSlider::SoundSlider( QWidget *_parent, int _i_step,
char *psz_colors ) char *psz_colors )
: QAbstractSlider( _parent ) : QAbstractSlider( _parent )
{ {
f_step = ( _i_step * 100 ) / AOUT_VOLUME_MAX ; f_step = (float)(_i_step * 10000)
/ (float)((SOUNDMAX - SOUNDMIN) * AOUT_VOLUME_DEFAULT);
setRange( SOUNDMIN, SOUNDMAX ); setRange( SOUNDMIN, SOUNDMAX );
setMouseTracking( true ); setMouseTracking( true );
isSliding = false; isSliding = false;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment